From 9df7919763b9349d3e62cbb936f366a55016b8fb Mon Sep 17 00:00:00 2001 From: Ilya Grigoriev Date: Thu, 16 Feb 2023 11:42:31 -0800 Subject: [PATCH] `config.md`: Fixup to complicated dotted example from 6cc7aa7 Added @martinvonz 's suggestion from https://github.com/martinvonz/jj/pull/1263. --- docs/config.md | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/docs/config.md b/docs/config.md index 26de904b6..36dc00451 100644 --- a/docs/config.md +++ b/docs/config.md @@ -2,6 +2,8 @@ These are the config settings available to jj/Jujutsu. + + The config settings are loaded from the following locations. Less common ways to specify `jj` config settings are discussed in a later section. @@ -17,14 +19,20 @@ e.g. `user.name = "YOUR NAME"` is equivalent to: name = "YOUR NAME" ``` -For a more complicated example, +For future reference, here are a couple of more complicated examples, ```toml +# Dotted style +template-aliases."format_short_id(id)" = "id.shortest(12)" +colors."commit_id prefix".bold = true + +# is equivalent to: [template-aliases] "format_short_id(id)" = "id.shortest(12)" -``` -is equivalent to `template-aliases."format_short_id(id)" = "id.shortest(12)"`. +[colors] +"commit_id prefix" = { bold = true } +``` Jujutsu favors the dotted style in these instructions, if only because it's easier to write down in an unconfusing way. If you are confident with TOML