diff options
author | Xavier Claessens <xavier.claessens@collabora.com> | 2023-01-13 16:42:09 -0500 |
---|---|---|
committer | Eli Schwartz <eschwartz93@gmail.com> | 2023-01-18 11:06:48 -0500 |
commit | 1a0eff005483b63259e365bd4d51be7c4bd3b729 (patch) | |
tree | 7b64867bb7ac42f9a0b441e4c375b4113eeea47b /docs/markdown/snippets | |
parent | 5a4168c410fea6fce8867ec60e0ba481d7c61866 (diff) | |
download | meson-1a0eff005483b63259e365bd4d51be7c4bd3b729.zip meson-1a0eff005483b63259e365bd4d51be7c4bd3b729.tar.gz meson-1a0eff005483b63259e365bd4d51be7c4bd3b729.tar.bz2 |
devenv: Allow dumping into file and select a format
It is often more useful to generate shell script than dumping to stdout.
It is also important to be able to select the shell format.
Formats currently implemented:
- sh: Basic VAR=prepend_value:$VAR
- export: Same as 'sh', but also export VAR
- vscode: Same as 'sh', but without substitutions because they don't
seems to work. To be used in launch.json's envFile.
Diffstat (limited to 'docs/markdown/snippets')
-rw-r--r-- | docs/markdown/snippets/devenv.md | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/docs/markdown/snippets/devenv.md b/docs/markdown/snippets/devenv.md new file mode 100644 index 0000000..c2ce2ad --- /dev/null +++ b/docs/markdown/snippets/devenv.md @@ -0,0 +1,11 @@ +## Dump devenv into file and select format + +`meson devenv --dump [<filename>]` command now takes an option filename argument +to write the environment into a file instead of printing to stdout. + +A new `--dump-format` argument has been added to select which shell format +should be used. There are currently 3 formats supported: +- `sh`: Lines are in the format `VAR=/prepend:$VAR:/append`. +- `export`: Same as `sh` but with extra `export VAR` lines. +- `vscode`: Same as `sh` but without `$VAR` substitution because they do not + seems to be properly supported by vscode. |