syncthing / syncthing/syncthing
A command to wait for sync
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 88.8k
- Forks
- 5.5k
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 5
Description
I would like a command that blocks until the current folder is fully synchronized.
Why? I have a directory on my "local" machine with my data and my remote computer that I ssh into, which processes the data. Sometimes I make a small change to the data and want to process it. Let's say I process the data with make. Right now, if I make a small change locally and then immediately type in make, my remote server won't see the changes for several seconds, which means I don't know what I'm making.
So, instead of typing in make on my local server, I type in something like syncthing sync && make
syncthing syncimmediately fails if all of my remotes are not connected- Then it makes sure that the synchronization is complete, which means that local and remote servers have detected and transferred all changes
- syncthing exits (no error code), which means that the files match the remote files.
- make is now sure to complete properly
There are no alternatives other than waiting, and there's no way to know how long to wait.
I write this like "syncthing sync" verifies that all files are synced the syncthing folder that $PWD is contained in, it could alternately be all syncthing folders that are "mounted" on the local machine.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the proposed syncthing sync command and trace how the current folder, remote connections, and synchronization state are exposed. Clarify the folder scope and failure behavior described in the issue, then verify that the command waits for detected and transferred changes before make runs.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- cli, distributed-systems
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100