Revised configuration (Future feature)

This is a draft of how the new configuration might look. It's also out of sync with the on-going naming/type-safe revamp. Nothing here is definitive, let me know if you have any suggestions.

Up until now the configuration file syntax is vaguely defined, specially when it comes to variables resolution. A new syntax will be introduced with a clearer definition.

i.e. current syntax:


will be a string assignment so

OPTION=some $value

will mean OPTION value is literally some $value

In OPTION= value # comment, OPTION takes the value “value”, trimmed of spaces and without comment.

In OPTION=| value # comment|, OPTION takes the value “ value # comment”

FIXME Support unmatched? (OPTION=| value # comment)

Inline comments will be explicitly allowed, # can be included in values through the use of Literal assignments (=|).

FIXME Maybe also through some escape sequence.

In OPTION=$value, OPTION takes the value “$value”, literally.

In OPTION=$value$, OPTION takes the value of the variable $value.

FIXME Support unmatched? (OPTION=$value)

Variables local to a configuration file will be allowed, so that:


Can be simplified as:


FIXME All other syntax changes use modified = syntax with a postfix, might be more efficient to use them too (i.e. =:value instead of :=value)

(Upon consideration) OPTION⇒$value$ will take the same value the variable $value has when OPTION is used (i.e. instead of the value it has when the configuration is parsed).

Currently per-user configuration is located in ~/.vcs.conf, it will probably be moved to a dot-directory (candidates are ~/.vcs, ~/.config/vcs, or maybe ~/.local/share/vcs).
Also /etc/vcs for site-wide config.
The switch to directories won't be required until some of the features using extra files (like profiles and plugins) are implemented.

Specs for ~/.local/share and ~/.config


  • ~/.config appears to be an XDG standard and apparently should be limited to standard-specific uses 1)

All dates/times in this page are UTC.
  • vcs/docs/devel/conf/new_syntax.txt
  • Last modified: 2016/04/17 23:28
  • by Toni Corvera