summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMel <mel@rnrd.eu>2026-01-11 18:30:12 +0100
committerMel <mel@rnrd.eu>2026-01-11 18:39:05 +0100
commite969da0511ace3d0910f464eacc1b4db4c2ff93f (patch)
treeb412b55a0f66668d9a8bf9e1a45ba89d745df3a3
parent6fdc47c9606ddd298c7c9e5f9b83ec095e89998b (diff)
downloadminerals-e969da0511ace3d0910f464eacc1b4db4c2ff93f.tar.zst
minerals-e969da0511ace3d0910f464eacc1b4db4c2ff93f.zip
Update Bismuth monitor layout
Signed-off-by: Mel <mel@rnrd.eu>
-rw-r--r--configs/monitors.xml75
-rw-r--r--machines/bismuth/default.nix8
-rw-r--r--machines/bismuth/home.nix10
3 files changed, 23 insertions, 70 deletions
diff --git a/configs/monitors.xml b/configs/monitors.xml
index d5d7f3e..a891b26 100644
--- a/configs/monitors.xml
+++ b/configs/monitors.xml
@@ -1,37 +1,14 @@
<monitors version="2">
- <!-- only primary, physical, no ghost -->
+ <!-- both monitors -->
<configuration>
<layoutmode>physical</layoutmode>
<logicalmonitor>
<x>0</x>
<y>0</y>
<scale>2</scale>
- <primary>yes</primary>
<monitor>
<monitorspec>
<connector>DP-2</connector>
- <vendor>GBT</vendor>
- <product>M28U</product>
- <serial>22120B002639</serial>
- </monitorspec>
- <mode>
- <width>3840</width>
- <height>2160</height>
- <rate>144.000</rate>
- </mode>
- </monitor>
- </logicalmonitor>
- </configuration>
- <!-- 2-monitor, physical, no ghost -->
- <configuration>
- <layoutmode>physical</layoutmode>
- <logicalmonitor>
- <x>0</x>
- <y>0</y>
- <scale>2</scale>
- <monitor>
- <monitorspec>
- <connector>DP-1</connector>
<vendor>DEL</vendor>
<product>DELL U2720Q</product>
<serial>1JSXZ83</serial>
@@ -50,7 +27,7 @@
<primary>yes</primary>
<monitor>
<monitorspec>
- <connector>DP-2</connector>
+ <connector>DP-3</connector>
<vendor>GBT</vendor>
<product>M28U</product>
<serial>22120B002639</serial>
@@ -63,7 +40,7 @@
</monitor>
</logicalmonitor>
</configuration>
- <!-- only primary, physical, ghost added -->
+ <!-- secondary (left) monitor only -->
<configuration>
<layoutmode>physical</layoutmode>
<logicalmonitor>
@@ -74,36 +51,6 @@
<monitor>
<monitorspec>
<connector>DP-2</connector>
- <vendor>GBT</vendor>
- <product>M28U</product>
- <serial>22120B002639</serial>
- </monitorspec>
- <mode>
- <width>3840</width>
- <height>2160</height>
- <rate>144.000</rate>
- </mode>
- </monitor>
- </logicalmonitor>
- <disabled>
- <monitorspec>
- <connector>None-1</connector>
- <vendor>unknown</vendor>
- <product>unknown</product>
- <serial>unknown</serial>
- </monitorspec>
- </disabled>
- </configuration>
- <!-- 2-monitor, physical, ghost added -->
- <configuration>
- <layoutmode>physical</layoutmode>
- <logicalmonitor>
- <x>0</x>
- <y>0</y>
- <scale>2</scale>
- <monitor>
- <monitorspec>
- <connector>DP-1</connector>
<vendor>DEL</vendor>
<product>DELL U2720Q</product>
<serial>1JSXZ83</serial>
@@ -115,14 +62,18 @@
</mode>
</monitor>
</logicalmonitor>
+ </configuration>
+ <!-- primary (right) monitor only -->
+ <configuration>
+ <layoutmode>physical</layoutmode>
<logicalmonitor>
- <x>3840</x>
+ <x>0</x>
<y>0</y>
<scale>2</scale>
<primary>yes</primary>
<monitor>
<monitorspec>
- <connector>DP-2</connector>
+ <connector>DP-3</connector>
<vendor>GBT</vendor>
<product>M28U</product>
<serial>22120B002639</serial>
@@ -134,13 +85,5 @@
</mode>
</monitor>
</logicalmonitor>
- <disabled>
- <monitorspec>
- <connector>None-1</connector>
- <vendor>unknown</vendor>
- <product>unknown</product>
- <serial>unknown</serial>
- </monitorspec>
- </disabled>
</configuration>
</monitors>
diff --git a/machines/bismuth/default.nix b/machines/bismuth/default.nix
index 02fda0f..a70d93c 100644
--- a/machines/bismuth/default.nix
+++ b/machines/bismuth/default.nix
@@ -15,10 +15,10 @@
];
# set monitor configuration for gdm
- # NOTE: maybe also use this for ~/.config/monitors.xml?
- systemd.tmpfiles.rules = [
- "L+ /run/gdm/.config/monitors.xml - - - - ${../../configs/monitors.xml}"
- ];
+ # see ./home.nix for user session monitors
+ environment.etc = {
+ "xdg/monitors.xml".source = ../../configs/monitors.xml;
+ };
system.stateVersion = "23.11";
}
diff --git a/machines/bismuth/home.nix b/machines/bismuth/home.nix
index 2ba6f25..1eb223e 100644
--- a/machines/bismuth/home.nix
+++ b/machines/bismuth/home.nix
@@ -5,5 +5,15 @@
../../modules/home/common.nix
];
+ xdg.configFile = {
+ # monitor configuration for user, for user session and shell
+ # gdm runs outside of the user session, and we also set monitors
+ # for it, in ./default.nix
+ "monitors.xml" = {
+ source = ../../configs/monitors.xml;
+ force = true; # overwrite on change so that the source of truth is the declarative version
+ };
+ };
+
home.stateVersion = "23.11";
}