Glyph - Project Configuration

Glyph stores configuration settings in the following YAML files:

  1. Your Project Configuration is stored in the config.yml file, included in each Glyph Project.
  2. Your Global Configuration is stored in a .glyphrc file in your $HOME (or %HOMEPATH% on Windows) directory (not created by default).
  3. The System Configuration is stored in the source directory of Glyph itself.

When compiling, Glyph loads all these configuration files and merges them according to the following rules:

  • A setting configured in the Project Configuration overrides the same setting in both Global and System configuration.
  • A setting configured in the Global Configuration overrides the same setting in the System Configuration.

Typically, you should use the Project Configuration for all project-specific settings and the Global Configuration for settings affecting all your projects (for example, you may want to set the setting in the Global Configuration instead of setting it in the Project Configuration of all your Glyph projects). The System Configuration is best left untouched.

Instead of editing your configuration settings directly, you can use the config command, as follows:

glyph config setting [value]

If no value is specified, Glyph prints the value of the configuration setting, so typing glyph config right after creating a project (assuming you didn’t set this in the Global Configuration) will print nothing, because this setting is blank by default.

To change the value of a configuration setting, specify a value right after the setting, like this:

glyph config "John Smith"

In this way, the document author will be set to John Smith for the current project. To save this setting globally, add a -g option, like this:

glyph config -g "John Smith"

There are plenty of configuration settings that can be modified, but most of them are best if left alone (and in the System Configuration file).

For a complete reference, see Configuration Reference. For everyday use, you may just want to change the settings defined in the document.* namespace.