extra wsl display commands

nix-components
pegasust 2022-11-10 18:42:35 +00:00
parent 529a7bffb4
commit 0cffc0e2aa
2 changed files with 16 additions and 0 deletions

View File

@ -47,6 +47,11 @@
myHome = {
username = "nixos";
homeDirectory = "/home/nixos";
shellInitExtra = ''
# x11 output for WSL
export DISPLAY=$(ip route list default | awk '{print $3}'):0
export LIBGL_ALWAYS_INDIRECT=1
'';
};
};
};
@ -60,6 +65,11 @@
myHome = {
username = "ubuntu_admin";
homeDirectory = "/home/ubuntu_admin";
shellInitExtra = ''
# x11 output for WSL
export DISPLAY=$(ip route list default | awk '{print $3}'):0
export LIBGL_ALWAYS_INDIRECT=1
'';
};
};
};

View File

@ -74,6 +74,11 @@
# https://github.com/nix-community/home-manager/pull/3287
# extraConfig = builtins.readFile ../neovim/init.lua;
};
programs.bash = {
enable = true;
enableCompletion = true;
initExtra = myHome.shellInitExtra or "";
};
programs.zsh = {
enable = true;
enableCompletion = true;
@ -90,6 +95,7 @@
enable = true;
plugins = [ "git" "sudo" "command-not-found" "gitignore" "ripgrep" "rust" ];
};
initExtra = myHome.shellInitExtra or "";
};
programs.git = {
enable = true;