About textual configuration files
Most of the time, needing to deal with text-based configuration files directly can be avoided by using the GUI.
When a text-based configuration file is needed you can specify it on the command-line using the --config option. Example:
synergys --config /path/to/synergy.conf
Example textual configuration file
This example comes from doc/synergy-basic.conf
# sample synergy configuration file # # comments begin with the # character and continue to the end of # line. comments may appear anywhere the syntax permits. # +-------+ +--------+ +---------+ # |Laptop | |Desktop1| |iMac | # | | | | | | # +-------+ +--------+ +---------+ section: screens # three hosts named: Laptop, Desktop1, and iMac # These are the nice names of the hosts to make it easy to write the config file # The aliases section below contain the "actual" names of the hosts (their hostnames) Laptop: Desktop1: iMac: end section: links # iMac is to the right of Desktop1 # Laptop is to the left of Desktop1 Desktop1: right = iMac left = Laptop # Desktop1 is to the right of Laptop Laptop: right = Desktop1 # Desktop1 is to the left of iMac iMac: left = Desktop1 end section: aliases # The "real" name of iMac is John-Smiths-iMac-3.local. If we wanted we could remove this alias and instead use John-Smiths-iMac-3.local everywhere iMac is above. Hopefully it should be easy to see why using an alias is nicer iMac: John-Smiths-iMac-3.local end
section: screens client1: preserveFocus = true # Don't drop focus when switching screens end
See also: the man page for synergys
Why would I want to use a text-based config?
The number one reason is that you don't really have a choice. If you aren't using a gui than you have to use a text-based config file.
The second reason is that it gives you more control. The GUI cannot create advanced configuration such as non-reciprocal connections. An example of a non-reciprocal connection would be that if you go right from screen A you get to screen B, but if you then go left from screen B you get to screen C rather than back to screen A as you would in a reciprocal connection.
- You can use a version control system
- It's easier to share configs with people
- You can have multiple config files (like if you use a laptop in multiple places)
The GUI actually creates a text-based config behind the scenes.