docs/term: add information to make it work with WSL (#936)
* docs/term: add information to make it work with WSL * Adapt recent changes that automatically set WSLENV, add info on how to install terminfo with nixpkgs * Apply suggestions from code review Co-authored-by: Wez Furlong <wez@wezfurlong.org>
This commit is contained in:
1 parent
092effba04
commit
4a8c4d1c30
1 file changed
+13
@@ -22,3 +22,16 @@ as colored underlines, styled underlines (eg: undercurl). If the system
|
||||
you are using has a relatively outdated ncurses installation, the `wezterm`
|
||||
terminfo will also enable italics and true color support.
|
||||
|
||||
If you are using WSL, wezterm will automatically populate `WSLENV` to properly set TERM, COLORTERM, TERM_PROGRAM and TERM_PROGRAM_VERSION in the environment when crossing between win32 and WSL environments.
|
||||
See [this Microsoft blog post](https://devblogs.microsoft.com/commandline/share-environment-vars-between-wsl-and-windows/#what-are-environment-variables) for more information on how `WSLENV` works.
|
||||
|
||||
If your package manager installed the terminfo data in a non-standard location, which will likely be the case if your are using nixpkgs/home-manager/NixOS, then you need to set `TERMINFO_DIRS` in the environment in order for applications to find it.
|
||||
The following snippet works if you installed `wezterm.terminfo` with nix into your user profile. Update the path to `TERMINFO_DIRS` to match the location on your system.
|
||||
|
||||
```lua
|
||||
set_environment_variables={
|
||||
TERMINFO_DIRS='/home/user/.nix-profile/share/terminfo',
|
||||
WSLENV='TERMINFO_DIRS'
|
||||
},
|
||||
term = "wezterm",
|
||||
```
|
||||
Reference in new issue
Block a user