Normally, the format should be readable for both humans and computers. It should be usable indepent of programming language. But how to pick one from the never ending list of options: json, yaml, toml, xml, ini etc. ?
There is one important limitation though: it’s not a
programming language. All those lack the expressiveness of one.
This means we don’t have mechanisms to avoid repetetions or
validate data easily. A potential solution to this is the newly
introduced format of pkl
. Read more.
Specify as argument or flag
man hostname
:
When called with one argument or with the –file option, the commands set the host name or the NIS/YP domain name.
Look for a specific filename
man make
:
make executes commands in the makefile to update one or more target names, where name is typically a program. If no -f option is present, make will look for the makefiles GNUmakefile, makefile, and Makefile, in that order.
Use if it’s project configuration that needs version control. Otherwise prefer explicit over implicit and expect file path.
Load from default path
man podman
:
CONFIGURATION FILES containers.conf (/usr/share/containers/containers.conf, /etc/containers/containers.conf, $HOME/.config/containers/containers.conf)
Use if it’s specific for a system. Don’t forget to ship a default configuration file. Add flags that can be used to skip all initializations (by giving the name “none”).
Terminology: positional arguments and options(flags)
#sw #configuration