From: Noor Haddad Date: Tue, 06 Oct 2026 10:05:03 +0300 Subject: [PATCH hello-hut 3/3] docs: document --lang To: ~reviewer/hello-hut-devel@lists.hut.md Message-ID: <20261006070500.48213-3-noor@example.org> In-Reply-To: <20261006070500.48213-0-noor@example.org> References: <20261006070500.48213-0-noor@example.org> --- README.md | 5 ++++- docs/configuration.md | 2 ++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 3e2a4f0..989533a 100644 --- a/README.md +++ b/README.md @@ -25,6 +25,8 @@ $ hello-hut Ada --shout HELLO, ADA! $ hello-hut --time-of-day Grace Good evening, Grace! +$ hello-hut --lang fr Ada +Bonjour, Ada! ``` ## Options @@ -37,6 +39,7 @@ Good evening, Grace! | `--count N` | Repeat the greeting `N` times | `1` | | `--color WHEN` | `auto`, `always` or `never`; `NO_COLOR` is respected | `auto` | | `--format FORMAT` | `text` or `json` | `text` | +| `--lang CODE` | Greeting language: `ar`, `de`, `en`, `es`, `fr`, `ja`, `pt`, `sv`, `tr` | `en` | ## Configuration @@ -56,7 +59,7 @@ Every key is described in [docs/configuration.md](docs/configuration.md). - [x] Configuration file - [x] `--count`, `--color` and `--format json` - [x] Bash and zsh completions -- [ ] Localized greetings with `--lang` +- [x] Localized greetings with `--lang` (on the `next` branch) - [ ] A man page - [ ] ~~Rhyming greetings~~ (out of scope, see the tracker) diff --git a/docs/configuration.md b/docs/configuration.md index fc43450..946a04e 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -9,6 +9,7 @@ win over the file. | --- | --- | --- | | `name` | string | Who to greet when no `NAME` is given | | `shout` | boolean | Shout by default | +| `lang` | string | Default greeting language, e.g. `"fr"` | Example: @@ -16,6 +17,7 @@ Example: # ~/.config/hello-hut/config.toml name = "Ada" shout = false +lang = "fr" ``` ## Notes -- 2.51.0