Skip to content

Commit 4121da2

Browse files
committed
update config for $ENV feature
1 parent d75d5fc commit 4121da2

1 file changed

Lines changed: 36 additions & 25 deletions

File tree

docs/docs/config.mdx

Lines changed: 36 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -95,34 +95,34 @@ wsh editconfig
9595
| window:dimensions | string | set the default dimensions for new windows using the format "WIDTHxHEIGHT" (e.g. "1920x1080"). when a new window is created, these dimensions will be automatically applied. The width and height values should be specified in pixels. |
9696
| telemetry:enabled | bool | set to enable/disable telemetry |
9797

98-
For reference, this is the current default configuration (v0.10.4):
98+
For reference, this is the current default configuration (v0.11.5):
9999

100100
```json
101101
{
102-
"ai:preset": "ai@global",
103-
"ai:model": "gpt-4o-mini",
104-
"ai:maxtokens": 2048,
105-
"ai:timeoutms": 60000,
106-
"app:defaultnewblock": "term",
107-
"autoupdate:enabled": true,
108-
"autoupdate:installonquit": true,
109-
"autoupdate:intervalms": 3600000,
110-
"conn:askbeforewshinstall": true,
111-
"conn:wshenabled": true,
112-
"editor:minimapenabled": true,
113-
"web:defaulturl": "https://github.com/wavetermdev/waveterm",
114-
"web:defaultsearch": "https://www.google.com/search?q={query}",
115-
"window:tilegapsize": 3,
116-
"window:maxtabcachesize": 10,
117-
"window:nativetitlebar": true,
118-
"window:magnifiedblockopacity": 0.6,
119-
"window:magnifiedblocksize": 0.9,
120-
"window:magnifiedblockblurprimarypx": 10,
121-
"window:magnifiedblockblursecondarypx": 2,
122-
"window:confirmclose": true,
123-
"window:savelastwindow": true,
124-
"telemetry:enabled": true,
125-
"term:copyonselect": true
102+
"ai:preset": "ai@global",
103+
"ai:model": "gpt-4o-mini",
104+
"ai:maxtokens": 2048,
105+
"ai:timeoutms": 60000,
106+
"app:defaultnewblock": "term",
107+
"autoupdate:enabled": true,
108+
"autoupdate:installonquit": true,
109+
"autoupdate:intervalms": 3600000,
110+
"conn:askbeforewshinstall": true,
111+
"conn:wshenabled": true,
112+
"editor:minimapenabled": true,
113+
"web:defaulturl": "https://github.com/wavetermdev/waveterm",
114+
"web:defaultsearch": "https://www.google.com/search?q={query}",
115+
"window:tilegapsize": 3,
116+
"window:maxtabcachesize": 10,
117+
"window:nativetitlebar": true,
118+
"window:magnifiedblockopacity": 0.6,
119+
"window:magnifiedblocksize": 0.9,
120+
"window:magnifiedblockblurprimarypx": 10,
121+
"window:magnifiedblockblursecondarypx": 2,
122+
"window:confirmclose": true,
123+
"window:savelastwindow": true,
124+
"telemetry:enabled": true,
125+
"term:copyonselect": true
126126
}
127127
```
128128

@@ -134,6 +134,17 @@ files as well: `termthemes.json`, `presets.json`, and `widgets.json`.
134134

135135
:::
136136

137+
## Environment Variable Resolution
138+
139+
To avoid putting secrets directly in config files, Wave supports environment variable resolution using `$ENV:VARIABLE_NAME` or `$ENV:VARIABLE_NAME:fallback` syntax.
140+
141+
```json
142+
{
143+
"ai:apitoken": "$ENV:OPENAI_APIKEY",
144+
"ai:baseurl": "$ENV:AI_BASEURL:https://api.openai.com/v1"
145+
}
146+
```
147+
137148
## WebBookmarks Configuration
138149

139150
WebBookmarks allows you to store and manage web links with customizable display preferences. The bookmarks are stored in a JSON file (`bookmarks.json`) as a key-value map where the key (`id`) is an arbitrary identifier for the bookmark. By convention, you should start your ids with "bookmark@". In the web widget, you can pull up your bookmarks using <Kbd k="Cmd:o"/>

0 commit comments

Comments
 (0)