Initial Commit
This commit is contained in:
12
content/configuration/_index.md
Normal file
12
content/configuration/_index.md
Normal file
@@ -0,0 +1,12 @@
|
||||
+++
|
||||
chapter = true
|
||||
pre = "<b>II. </b>"
|
||||
title = "Configuration"
|
||||
weight = 2
|
||||
+++
|
||||
|
||||
### Chapter II
|
||||
|
||||
# Configuration
|
||||
|
||||
This chapter is about configuring ITD, including documentation about its config file and locations where it can be put.
|
||||
12
content/configuration/about.md
Normal file
12
content/configuration/about.md
Normal file
@@ -0,0 +1,12 @@
|
||||
+++
|
||||
title = "About"
|
||||
date = 2021-10-23T23:04:51-07:00
|
||||
draft = true
|
||||
weight = 1
|
||||
+++
|
||||
|
||||
ITD has a config file. It's a TOML file that is, by default, at `/etc/itd.toml`. ITD will also search `~/.config/itd.toml` for a config and will choose the one in home if possible.
|
||||
|
||||
ITD can also be configured with environment variables. They take priority over the config. Variable names should be formatted as follows: ITD_<config field>. For example, socket path is `socket.path` in the config, so it would be `ITD_SOCKET_PATH` as an environment variable. To change which transliterators to use, `ITD_NOTIFS_TRANSLIT_USE` would be the variable, since the config field is `notifs.translit.use`.
|
||||
|
||||
In most cases, config edits come into effect immediately, and no restart of ITD is needed.
|
||||
105
content/configuration/sections.md
Normal file
105
content/configuration/sections.md
Normal file
@@ -0,0 +1,105 @@
|
||||
+++
|
||||
title = "Sections"
|
||||
date = 2021-10-23T23:04:51-07:00
|
||||
draft = true
|
||||
weight = 2
|
||||
+++
|
||||
|
||||
This page is about the various sections in the config, their purpose, and how to use them.
|
||||
|
||||
### cfg.version
|
||||
|
||||
This field is temporary and was added because I changed the config format a while ago and wanted to make sure no one was still using the old config with a new version of ITD.
|
||||
|
||||
---
|
||||
|
||||
### socket
|
||||
|
||||
This section contains options for the control socket exposed by ITD.
|
||||
|
||||
#### path
|
||||
|
||||
This field is a string indicating the filepath at which the control socket should be opened.
|
||||
|
||||
---
|
||||
|
||||
### conn
|
||||
|
||||
The conn secton contains options for ITD's connection to the PineTime.
|
||||
|
||||
#### reconnect
|
||||
|
||||
This field is a boolean that dictates whether ITD will attempt to reconnect to the PineTime in case of a disconnect.
|
||||
|
||||
---
|
||||
|
||||
### on.connect
|
||||
|
||||
This section contains options for what happens when ITD first connects to a PineTime.
|
||||
|
||||
#### notify
|
||||
|
||||
This field is a boolean that dictates whether a notification should be sent to InfiniTime upon connection.
|
||||
|
||||
---
|
||||
|
||||
### on.reconnect
|
||||
|
||||
This section contains options for what happens when ITD reconnects to a PineTime after a disconnect.
|
||||
|
||||
#### notify
|
||||
|
||||
This field is a boolean that dictates whether a notification should be sent to InfiniTime upon reconnect.
|
||||
|
||||
#### setTime
|
||||
|
||||
This field is a boolean that dictates whether the time should be updated when ITD reconnects to InfiniTime.
|
||||
|
||||
---
|
||||
|
||||
### notifs.translit
|
||||
|
||||
#### use
|
||||
|
||||
This field is an array of strings which sets which transliterators should be used when transliterating text. The full list of transliterators can be found [here](https://gitea.arsenm.dev/Arsen6331/itd#transliteration) in the readme.
|
||||
|
||||
#### custom
|
||||
|
||||
This field is an array of strings which is a custom transliteration map. It can replace anything with something else. For example:
|
||||
|
||||
```toml
|
||||
custom = [
|
||||
"test", "replaced",
|
||||
"æ", "ae",
|
||||
"ē", "e",
|
||||
]
|
||||
```
|
||||
|
||||
An array is used because Golang does not preserve the order of a map.
|
||||
|
||||
---
|
||||
|
||||
### notifs.ignore
|
||||
|
||||
#### sender
|
||||
|
||||
This field is an array of strings which contains senders from which notifications are ignored.
|
||||
|
||||
#### summary
|
||||
|
||||
This field is an array of strings which contains notification summaries whose notifications will be ignored.
|
||||
|
||||
|
||||
#### body
|
||||
|
||||
This field is an array of strings which contains notification bodies whose notifications will be ignored.
|
||||
|
||||
---
|
||||
|
||||
### music
|
||||
|
||||
This section contains options for music control
|
||||
|
||||
#### vol.interval
|
||||
|
||||
This field is an integer indicating how much the volume should be changed for each volume up or down event from the music control app.
|
||||
Reference in New Issue
Block a user