home/polybar: fix default monitor

This commit is contained in:
Dmitriy Pleshevskiy 2022-09-26 00:52:49 +03:00
parent 0ec6a2cc4f
commit 3c153d4a90
Signed by: pleshevskiy
GPG key ID: 1B59187B161C0215
2 changed files with 2 additions and 3 deletions

View file

@ -4,7 +4,7 @@ with lib;
{ {
"bar/main" = { "bar/main" = {
monitor = "DisplayPort-1"; monitor = "\${env:MONITOR:DisplayPort-1}";
width = "100%"; width = "100%";
height = "20px"; height = "20px";
font = [ font = [
@ -94,4 +94,3 @@ with lib;
}; };
}; };
} }

View file

@ -30,7 +30,7 @@ in
services.polybar = { services.polybar = {
enable = true; enable = true;
script = "polybar &"; script = "MONITOR=$(xrandr | grep \"connected primary\" | awk '{print $1;}') polybar &";
settings = polybarConfig; settings = polybarConfig;
}; };
}; };