Document environment variables all in one place

This commit is contained in:
Dustin J. Mitchell 2021-05-07 11:16:10 -04:00
parent 1d0ed132df
commit 7aea34c7a3
4 changed files with 23 additions and 11 deletions

View file

@ -6,9 +6,9 @@
* [Configuration](./config-file.md)
* [Reports](./reports.md)
* [Tags](./tags.md)
* [Environment](./environment.md)
* [Synchronization](./task-sync.md)
* [Running the Sync Server](./running-sync-server.md)
* [Debugging](./debugging.md)
- [Internal Details](./internals.md)
* [Data Model](./data-model.md)
* [Replica Storage](./storage.md)

View file

@ -6,7 +6,7 @@ Configuration is read from `taskchampion.toml` in your config directory.
On Linux systems, that directory is `~/.config`.
On OS X, it's `~/Library/Preferences`.
On Windows, it's `AppData/Roaming` in your home directory.
This can be overridden by setting `$TASKCHAMPION_CONFIG` to the configuration filename.
This can be overridden by setting `TASKCHAMPION_CONFIG` to the configuration filename.
The file format is [TOML](https://toml.io/).
For example:

View file

@ -1,9 +0,0 @@
# Debugging
Both `ta` and `taskchampion-sync-server` use [env-logger](https://docs.rs/env_logger) and can be configured to log at various levels with the `RUST_LOG` environment variable.
For example:
```shell
$ RUST_LOG=taskchampion=trace ta add foo
```
The output may provide valuable clues in debugging problems.

21
docs/src/environment.md Normal file
View file

@ -0,0 +1,21 @@
# Environment Variables
## Configuration
Set `TASKCHAMPION_CONFIG` to the location of a configuration file in order to override the default location.
## Terminal Output
Taskchampion uses [termcolor](https://github.com/BurntSushi/termcolor) to color its output.
This library interprets [`TERM` and `NO_COLOR`](https://github.com/BurntSushi/termcolor#automatic-color-selection) to determine how it should behave, when writing to a tty.
Set `NO_COLOR` to any value to force plain-text output.
## Debugging
Both `ta` and `taskchampion-sync-server` use [env-logger](https://docs.rs/env_logger) and can be configured to log at various levels with the `RUST_LOG` environment variable.
For example:
```shell
$ RUST_LOG=taskchampion=trace ta add foo
```
The output may provide valuable clues in debugging problems.