@ 260802.2

200921.1 · 9f7959f6bfa8997ccbf7177a04947a49cae0f3da

doc: improve system link docs

reading declarations

bin/rust/setup-system-links/README.md

new file mode 100644@@ -0,0 +1,27 @@+This tool implements my symlinking scheme for system wide machine specific+configuration files. In effect, it centralizes system config files (typically+found in `/etc`) into the `~/system` directory with a simple scheme for+managing per-machine configuration. See the README in `~/system` for more+details on the scheme.++The typical way in which this utility is run is to first confirm that the+changes look okay:++```+$ setup-system-links --dry-run+```++and then commit them:++```+$ sudo -E setup-system-links+```++Backups are made of each system config file before they are replaced, and the+output of the commands above show where the backup resides.++The main downside of this approach to configuration is that it makes these+config files user editable where as they are normally only configured via root.+But these days, most of my systems are single-user with `NOPASSWD` access to+`sudo`, so this isn't really a main difference maker in my setup. Therefore,+this scheme won't work well in more robust shared systems.

system/README.md

@@ -8,15 +8,17 @@ about a config before wiping a machine.  The general scheme is: -  $HOME/etc/path/to/config-file-as-directory/{default,krusty,...}+```+$HOME/system/etc/path/to/config-file-as-directory/{default,krusty,...}+``` -Where `/etc/path/to/config-file-as-directory` is a directory that refers to a-concrete file path in the /etc directory. Inside this directory is an optional-file named `default`, along with other optional files named by hostname, e.g.,-`krusty`. If a hostname file is present, then that file is symlinked to the-corresponding config file location. Otherwise the `default` file is. If no-files are present, then no symlinks are created. Thus, if you want to keep a-configuration checked into git but disable it, then rename it from `{name}` to-`{name}.disable`.+Where `/etc/path/to/config-file-as-directory` is a directory that refers+to a concrete file path in the `/etc` directory. Inside this directory is+an optional file named `default`, along with other optional files named by+hostname, e.g., `krusty`. If a hostname file is present, then that file is+symlinked to the corresponding config file location. Otherwise the `default`+file is. If no files are present, then no symlinks are created. Thus, if you+want to keep a configuration checked into git but disable it, then rename it+from `{name}` to `{name}.disable`. -symlinks are created by ~/bin/setup-system-links.+symlinks are created by `setup-system-links`.