about summary refs log tree commit diff
path: root/init/nixos.el
diff options
context:
space:
mode:
authorVincent Ambo <tazjin@gmail.com>2018-06-03T16·17+0200
committerVincent Ambo <tazjin@gmail.com>2018-06-03T16·20+0200
commitac527952ce9416a66414ca5e767c5a6ebefa3de1 (patch)
tree0116c6d7410e4fad7f6185b6dd68ad9053c7d476 /init/nixos.el
parent2e637433c12eb7a26f9c6c8512643df03fb311a0 (diff)
refactor(nixos): Only load exwm-randr on adho
Last attempt to at least work around
https://github.com/ch11ng/exwm/issues/425 on one of my machines before
reverting to an old EXWM version.

If the randr module is responsible for this issue it will probably
still occur on the laptop and I'll eventually downgrade, but it may be
a clue for debugging it at some point in the future.
Diffstat (limited to 'init/nixos.el')
-rw-r--r--init/nixos.el9
1 files changed, 5 insertions, 4 deletions
diff --git a/init/nixos.el b/init/nixos.el
index 4facf40ae741..a75695d0c8e3 100644
--- a/init/nixos.el
+++ b/init/nixos.el
@@ -43,7 +43,6 @@
       (message "Running on NixOS, configuring ExWM.")
       (require 'exwm)
       (require 'exwm-config)
-      (require 'exwm-randr)
 
       (fringe-mode 3)
 
@@ -92,9 +91,11 @@
       ;; Show time in the mode line
       (display-time-mode)
 
-      ;; Another attempt at xrandr configuration
-      (setq exwm-randr-workspace-output-plist (generate-randr-config))
-      (exwm-randr-enable)
+      ;; Configure xrandr when running on laptop
+      (when (equal (shell-command-to-string "hostname") "adho\n")
+        (require 'exwm-randr)
+        (setq exwm-randr-workspace-output-plist (generate-randr-config))
+        (exwm-randr-enable))
 
       ;; Let buffers move seamlessly between workspaces
       (setq exwm-workspace-show-all-buffers t)