0

I have a folder on my Mac and corresponding folder on my Android phone, which I would like to keep in sync both ways. ie. sometimes work is done on my phone, sometimes work is done on my Mac.

I technically don't require versioning history, but nevertheless it's a nice to have.

I have tried Google Drive - Backup & Sync for this purpose, but I didn't like the fact that I require a special file explorer on my phone and it "streams" the files so the access is always laggy.

I also don't want to use DropBox for similar reasons.

I have termux running on my phone and have been able to sync via a remote origin on Atlassian BitBucket, however the problem I'm foreseeing is that BitBucket have set a limit (1GB soft/2GB hard) on the size of the repository specifically to curb being used as a file-sharing service.

Is there a better way to do this than Git?

2 Answers 2

1

Git is not a backup or syncing tool. Git can sync data that's versioned, sure, but its goal is to be a version control system, and as you've found, it doesn't work very well as a syncing tool. For example, Git doesn't sync most permissions across machines.

If you don't want to sync the two with a cloud syncing service, you can do so with a tool like rsync, which is usually used in conjunction with SSH. There are a variety of other tools out there as well.

If you want to use rsync, you can do rsync -a --delete-after SOURCE DEST. Generally, one of those paths will be a remote rsync location and one will be a local path.

4
  • I like the rsync proposal, but can you please expand on how it could be used? my dilemma is that files will be added and removed on both the remote and local sides, i need changes to either side to be reflected - git is very good at doing this because there is a commit stage to the process Commented Apr 29, 2021 at 3:58
  • that is i want: removed on local -> removed on remote; added on local -> added on remote; removed on remote -> removed on local; added on remote -> added on local Commented Apr 29, 2021 at 4:01
  • I've edited the answer to explain some command line options to use.
    – bk2204
    Commented Apr 29, 2021 at 22:20
  • i've accepted this answer because it pointed me in the right direction and Mecki's solution on stackoverflow got me very close to where i wanted to get Commented Feb 8 at 11:16
-1

you can try using syncthing or folder sync app.

1
  • 1
    Explaining HOW to use these tools to solve the problem presented may make it an answer. Right now it is just a comment, and as such, does not belong here. If you wish to improve this please use the EDIT button to do so. Commented Apr 15, 2021 at 1:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .