mirror of
https://github.com/nushell/nushell.git
synced 2025-08-19 00:46:01 +02:00
Closes #15786 ## Release notes summary - What our users need to know `std-rfc/kv` commands now take an optional `--table (-t)` argument which allows a custom table name to be used. If not specified, the current `std-kv-store` table will be used. ## Tasks after submitting - [x] Added in-help example to `kv set`. Did not add examples to the other `kv` commands since they should be obvious based on the initial `kv set`. ## Additional details Example: ```nushell use std-rfc/kv * kv set -t foo bar 5 kv list # Empty list, since the value was placed in a custom table # => ╭────────────╮ # => │ empty list │ # => ╰────────────╯ kv list -t foo # => ╭───┬─────┬───────╮ # => │ # │ key │ value │ # => ├───┼─────┼───────┤ # => │ 0 │ bar │ 5 │ # => ╰───┴─────┴───────╯ ``` To protect against injection attacks, table names can only include alphanumeric characters with `_` and `-`.