Configure sessions and appearance

GoCDM parses cdmrc data itself; it does not source it as a shell program. An explicit -config PATH or positional RCFILE takes precedence. Supplying both nonempty forms is an error. Otherwise ordinary user mode searches:

  1. $HOME/.cdmrc
  2. $XDG_CONFIG_HOME/cdm/cdmrc, or $HOME/.config/cdm/cdmrc when XDG_CONFIG_HOME is unset
  3. /etc/cdmrc

In direct getty mode, pre-login settings come from the explicit file or /etc/cdmrc. User settings are loaded after authentication under the canonical account’s credentials. Relative user theme paths are resolved against that account’s home. If there is no config, built-in defaults and installed-session discovery apply. The program does not require /etc/gocdm and does not create /etc/cdmrc automatically.

Choose explicit sessions

binlist=("/bin/bash" "startplasma-wayland" "xterm")
namelist=("Console" "Plasma Wayland" "X terminal")
flaglist=("C" "W" "X")

Use C for console, W for Wayland and X for X11. Keep the arrays aligned. Commands support quoted arguments, not arbitrary shell evaluation, redirection or command substitution. Use an executable script when a session needs more setup. Omit binlist to discover installed desktop entries and registered shells.

Remember a selection

Development builds save a stable session key alongside its display name in ~/.config/gocdm/state.json. Renaming a label or reordering configured entries therefore keeps the same selected command. Identical configured commands of the same kind appear once; entries with the same label and different commands remain separate choices.

Older name-only state selects a session only when the label is unique. A duplicate legacy label or a saved key which is no longer available uses the first displayed entry. There is no manual state migration step. Inspect ownership and symlinks if state cannot be saved; GoCDM does not recursively repair a user’s files.

Appearance and X11 settings

dialogrc points to a theme file, for example an installed file under /usr/local/share/gocdm/themes/. Use an absolute path. countfrom controls menu numbering. Example X11 settings:

xtty=keep
locktty=no
startxlog="/dev/null"
serverargs=("-nolisten" "tcp")

xtty=keep uses the current VT. A number chooses a base VT. In direct getty mode, the administrator configuration controls xtty, display and locktty. An existing display requested by locktty=yes cannot be reused through direct login because GoCDM cannot verify who owns it. In ordinary user mode, the existing X handoff remains available with the permissions of the current session. consolekit=no disables the legacy ConsoleKit wrapper; when unset, GoCDM skips it in an established logind session or when absent. altstartx and nondefault ConsoleKit timeout handling are deprecated and may error.

Use gocdm help to inspect options on the development version with the generated CLI. Older published versions use gocdm -help and gocdm -version; current development uses gocdm version. Single-dash long flags and double-dash equivalents are accepted. For a literal config file named version, help or usage, place it after --.

-dry-run prints the selected command; -debug-env is a troubleshooting aid during actual preparation, not a promise to print an environment in every dry-run branch. Treat even redacted diagnostics as potentially personal before sharing them.