syncthing-merge automatically merges conflicts generated by Syncthing.
syncthing-merge --config PATH
syncthing-url = "" # URL at which Syncthing is accessible
syncthing-api-key-file = "" # Path to file containing Syncthing API key
# Each `merge-target` is a folder that contains mergeable files
[[merge-target]]
folder-id = "" # Syncthing ID of the folder
folder-name = "" # Folder name
# Each `merge-target.file` is a file (within the most recently defined `merge-target`) whose conflicting versions can be merged
[[merge-target.file]]
name = "" # File name
program = "" # Program that merges conflicting file versionsThe program must take two arguments:
- The original file
- The conflicting file
Syncthing renames the older file in a conflicting pair, so the program should merge the original file "onto" the conflicting file if merging is not commutative.
The program should clean up by ensuring that the only remaining file is the merged result, which should be renamed to the original file.