Unison is a tool to compare and synchronize two folders. You can configure it by GUI, but at least for me (Kubuntu 18.04) not all settings work. Specifically, I cannot set the value “0”. But there is an easy way around the problem. Unison puts a file called Profilename.prf
(where “Profilename” should be replaced with the actual name of your profile) into the folder .unison
in your home directory. This is simply a text file with key-value pairs, that you can edit at your leisure.
Here are standard settings for comparing two directories without comparing the file permissions:
label = My first comparison root = /home/test/FolderOne/ root = /home/test/FolderTwo/ perms = 0 dontchmod = true
Now for the coolest feature of Unison: It is written in OCaml!! OCaml was used in my third semester to teach functional programming. I remember clearly the teacher telling us about the “usefulness” of the language. She had one slide with examples of programs written in OCaml. And she must have looked very hard to find any. There were a grand total of three programs on the slide. Two formal logic resolvers or something to that effect (we were like “yeah, really useful”). And MLDonkey (peer-to-peer filesharing was BIG in those days before Netflix, Spotify and fast internet) which she clearly didn’t know what it was for. So now, if she still has that slide, I can add another program! And a really useful one at that!