Merge branch 'document-file' into 'main'

Document _file option suffix

See merge request kernald/reddit-magnet!21
This commit is contained in:
Marc Plano-Lesay 2025-05-03 05:20:45 +00:00
commit a9d0f00d2b

View file

@ -32,7 +32,7 @@ reddit-magnet [OPTIONS]
## Configuration
Reddit Magnet uses a TOML configuration file. By default, it looks for a configuration file at `$XDG_CONFIG_HOME/reddit-magnet/config.toml`, but you can specify a different location using the `--config` option.
Reddit Magnet uses a TOML configuration file. By default, it looks for a configuration file at `$XDG_CONFIG_HOME/reddit-magnet/config.toml`, but you can specify a different location using the `--config` option. Note that every option can be suffixed with `_file`, and the value set to a path - at runtime, this file will be read and its content will be assumed as the value for the option. This allows storing sensitive credentials somewhere else.
### Example configuration
@ -44,6 +44,7 @@ host = "http://localhost"
port = 9091
username = "username" # Optional
password = "password" # Optional
# Could also be password_file = "/run/secrets/reddit-magnet/transmission/password"
download_dir = "/downloads" # Optional
# BitMagnet configuration