3 ms·
Syncthing is excellent. I’ve used it for years to keep my development folders synced between mac, linux and windows, and except for some initial figuring out of
by Joeri 3y ago
Syncthing is excellent. I’ve used it for years to keep my development folders synced between mac, linux and windows, and except for some initial figuring out of ignore patterns and the occasional hiccup with filenames that windows can’t handle it has been great at doing what it needs to and getting out of my way.
(I of course also use git, but syncthing lets me choose when I push while still having all my work on all my machines.)
- thefz 3y ago> occasional hiccup with filenames that windows can’t handle My only complaint so far and I've been using it for years. At first it started as a way to have my Keepass file in sync between computers, and evolved from that.
- greenie_beans 3y agoi always heard it fucks up with git repos?
- generalizations 3y agoI have an entire folder dedicated to various git repos...only thing it doesn't like (so far...) is some compilation artifacts. IDK why.
- prophesi 3y agoI would make sure that there's a `.stignore` file that's identical to your `.gitignore` (except for secret keys/configs you'd like to sync on your devices) in each of those repositories.
- Joeri 3y agoYou can also make a global one for an entire shared folder. For example, I wildcard all node_modules folders as excluded.
- sveinugu 3y agoYeah, you need to add .git to the ignores. Works very well when you have only one repo checked out, for instance to auto-sync a deployment while you type, without having to commit and do CI/CD. With more than one repo you should be sure they are all on the same branch/commit before you sync. If not, you typically get a mess that requires some git-foo to clean up!
- mike-cardwell 3y agoI use it to store most of my private git repos and have been doing so for years now without a single issue. I do this: cd ~/Sync/git mkdir reponame cd reponame git init --bare cd ~/work git clone ~/Sync/git/reponame I guess this could break if I do a push and then shut my laptop lid before it syncs, and then do some more work on my desktop, push, and then go back to my laptop. That hasn't happened though. If it did, it should be trivial to fix. There was some other comment near here about ignoring .git directories. I guess they're using it to store the working directory rather than just the repository, as there is no .git directory stored in ~/Sync/ in my situation.
- karlicoss 3y agonot sure what happens if you commit on two devices before syncing, but the "worst" that happened to me is I get an index conflict, in which case it's easily fixed by 'git reset'
- vulcan01 3y agoFWIW, I've been using syncthing for 3 years now and have never had any issues with git repo syncs.
- raffraffraff 3y agoI do this too! Feels weird keeping code in sync between machines aside from git, but it works really well.