id = "xonsh" name = "Xonsh" homepage = "https://xon.sh" description = "A full-featured and cross-platform Python-based shell; the language is a superset of Python 3." # The project's own SVG favicon, from xon.sh. icon = "https://xon.sh/_static/xonsh_terminal_icon.svg" executables = ["xonsh"] [dotfiles] # https://xon.sh/xonshrc.html, "Run Control File": the user's control files are # `~/.xonshrc` and the XDG-compliant `~/.config/xonsh/rc.xsh`, plus the drop-in # directory `~/.config/xonsh/rc.d/` whose `.xsh` and `.py` files "will be # executed at startup in order". The `/etc/xonsh` copies of all three are # system-wide and left out. # # xonsh/environ.py is where those come from: `default_xonshrc` returns # `($XONSH_SYS_CONFIG_DIR/xonshrc, $XONSH_CONFIG_DIR/rc.xsh, ~/.xonshrc)`, # `default_xonshrcdir` returns the same two directories with `rc.d`, and # `xonsh_config_dir` is `os.getenv("XONSH_CONFIG_DIR") or # os.path.join(env.get("XDG_CONFIG_HOME"), "xonsh")` — the XDG config home read # from its variable, which is [configHome]. `get_home_xonshrc_path` builds # `~/.xonshrc` from the home directory, so that one is a plain dotfile. # # One caveat: xonsh declares its own `XDG_CONFIG_HOME` default as `~/.config` # on every platform, Windows included (environ.py, `XDG_CONFIG_HOME = # Var.with_default(os.path.expanduser(os.path.join("~", ".config")), …)`), so on # Windows the [configHome] spelling resolves to %APPDATA%, which xonsh does not # use. ~/.xonshrc is the location that holds there. paths = [ "~/.xonshrc", "[configHome]/xonsh/rc.xsh", "[configHome]/xonsh/rc.d/", ] # Same file: `xonsh_data_dir` is `$XONSH_DATA_DIR` or `$XDG_DATA_HOME/xonsh`, # and `xonsh_cache_dir` is `$XONSH_CACHE_DIR` or `$XDG_CACHE_HOME/xonsh`. The # data directory is where the history backend writes `$XONSH_HISTORY_FILE` and # where `default_completer_dirs` puts `generated_completions`, the completers # xonsh builds from man pages — history and generated state, not config. Both # variables are read, and xonsh's defaults for them are the dotted paths, so # they are [xdgData] and [xdgCache]. exclude = [ "[xdgData]/xonsh/", "[xdgCache]/xonsh/", ] # xonsh writes no credential file of its own. An rc file is Python and a user # can put a token in one, but that is the user's line, not a file xonsh keeps. secret = [] # No machine_lines. A xonshrc sets `$PATH` and friends the way every shell rc # does, but xonsh spells them as Python expressions — `$PATH.append(...)`, # `$PATH = [...]`, `$PATH.add(...)` — and a prefix rule matches the start of a # line, so no single keyword catches the machine-local ones without also # catching aliases and prompt settings the user wants carried. Left out rather # than guessed at.