jj-config*: add page (#20713)

Signed-off-by: Emmanuel Ferdman <emmanuelferdman@gmail.com>
This commit is contained in:
Emmanuel Ferdman
2026-01-13 17:39:19 +02:00
committed by GitHub
parent dd64943ef8
commit b95faef950
7 changed files with 161 additions and 0 deletions
+17
View File
@@ -0,0 +1,17 @@
# jj config edit
> Start an editor on a config file.
> See also: `jj config path`.
> More information: <https://docs.jj-vcs.dev/latest/cli-reference/#jj-config-edit>.
- Start an editor on the user-level config file:
`jj config {{[e|edit]}} --user`
- Start an editor on the repo-level config file:
`jj config {{[e|edit]}} --repo`
- Start an editor on the workspace-level config file:
`jj config {{[e|edit]}} --workspace`
+22
View File
@@ -0,0 +1,22 @@
# jj config get
> Get the value of a given config option.
> Unlike `jj config list`, the result is printed without extra formatting for use in scripts.
> See also: `jj config list`.
> More information: <https://docs.jj-vcs.dev/latest/cli-reference/#jj-config-get>.
- Get the value of a config option:
`jj config {{[g|get]}} {{name}}`
- Get the configured user name:
`jj config {{[g|get]}} user.name`
- Get the configured user email:
`jj config {{[g|get]}} user.email`
- Get the default revset for the log command:
`jj config {{[g|get]}} revsets.log`
+33
View File
@@ -0,0 +1,33 @@
# jj config list
> List variables set in config files, along with their values.
> See also: `jj config get`.
> More information: <https://docs.jj-vcs.dev/latest/cli-reference/#jj-config-list>.
- List all config variables and their values:
`jj config {{[l|list]}}`
- List a specific config option:
`jj config {{[l|list]}} {{name}}`
- List user-level config variables:
`jj config {{[l|list]}} --user`
- List repo-level config variables:
`jj config {{[l|list]}} --repo`
- List config variables including built-in default values:
`jj config {{[l|list]}} --include-defaults`
- List config variables including overridden values:
`jj config {{[l|list]}} --include-overridden`
- List config variables with a custom template:
`jj config {{[l|list]}} {{[-T|--template]}} {{template}}`
+17
View File
@@ -0,0 +1,17 @@
# jj config path
> Print the paths to the config files.
> See also: `jj config edit`.
> More information: <https://docs.jj-vcs.dev/latest/cli-reference/#jj-config-path>.
- Print the path to the user-level config file:
`jj config {{[p|path]}} --user`
- Print the path to the repo-level config file:
`jj config {{[p|path]}} --repo`
- Print the path to the workspace-level config file:
`jj config {{[p|path]}} --workspace`
+26
View File
@@ -0,0 +1,26 @@
# jj config set
> Set a config option to a given value.
> The value is specified as a TOML expression.
> See also: `jj config unset`.
> More information: <https://docs.jj-vcs.dev/latest/cli-reference/#jj-config-set>.
- Set the user name in the user-level config:
`jj config {{[s|set]}} --user user.name "{{name}}"`
- Set the user email in the user-level config:
`jj config {{[s|set]}} --user user.email "{{email}}"`
- Set a config option in the repo-level config:
`jj config {{[s|set]}} --repo {{name}} {{value}}`
- Set a config option in the workspace-level config:
`jj config {{[s|set]}} --workspace {{name}} {{value}}`
- Set a boolean config option:
`jj config {{[s|set]}} --user {{name}} {{true|false}}`
+17
View File
@@ -0,0 +1,17 @@
# jj config unset
> Unset a config option.
> See also: `jj config set`.
> More information: <https://docs.jj-vcs.dev/latest/cli-reference/#jj-config-unset>.
- Unset a config option in the user-level config:
`jj config {{[u|unset]}} --user {{name}}`
- Unset a config option in the repo-level config:
`jj config {{[u|unset]}} --repo {{name}}`
- Unset a config option in the workspace-level config:
`jj config {{[u|unset]}} --workspace {{name}}`
+29
View File
@@ -0,0 +1,29 @@
# jj config
> Manage config options.
> Some subcommands such as `edit`, `get`, `list`, `path`, `set`, `unset` have their own usage documentation.
> More information: <https://docs.jj-vcs.dev/latest/cli-reference/#jj-config>.
- Start an editor on the user-level config file:
`jj config {{[e|edit]}} --user`
- Get the value of a config option:
`jj config {{[g|get]}} {{name}}`
- List all config variables and their values:
`jj config {{[l|list]}}`
- Print the path to the user-level config file:
`jj config {{[p|path]}} --user`
- Set a config option in the user-level config:
`jj config {{[s|set]}} --user {{name}} {{value}}`
- Unset a config option in the user-level config:
`jj config {{[u|unset]}} --user {{name}}`