diff options
Diffstat (limited to 'init/nixos.el')
-rw-r--r-- | init/nixos.el | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/init/nixos.el b/init/nixos.el index 2fc5bc434027..3caeec9a5c01 100644 --- a/init/nixos.el +++ b/init/nixos.el @@ -4,6 +4,7 @@ (require 's) (require 'f) +(require 'dash) (defvar is-nixos (let ((os-f "/etc/os-release")) @@ -32,11 +33,17 @@ (interactive) (shell-command "i3lock")) +(defun generate-randr-config () + (-flatten `(,(-map (lambda (n) (list n "DP2")) (number-sequence 1 5)) + (0 "eDP1") + ,(-map (lambda (n) (list n "eDP1")) (number-sequence 6 9))))) + (if is-nixos (progn (message "Running on NixOS, configuring ExWM.") (require 'exwm) (require 'exwm-config) + (require 'exwm-randr) (fringe-mode 3) @@ -85,6 +92,10 @@ ;; 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) + ;; Let buffers move seamlessly between workspaces (setq exwm-workspace-show-all-buffers t) (setq exwm-layout-show-all-buffers t))) |