summaryrefslogtreecommitdiffstats
path: root/.emacs.d
diff options
context:
space:
mode:
Diffstat (limited to '.emacs.d')
-rw-r--r--.emacs.d/init.el30
1 files changed, 13 insertions, 17 deletions
diff --git a/.emacs.d/init.el b/.emacs.d/init.el
index 10d84dd..71f86d5 100644
--- a/.emacs.d/init.el
+++ b/.emacs.d/init.el
@@ -184,6 +184,9 @@
;;; Initial setup
+(defvar b/exwm-p (string= (system-name) "jirud")
+ "Whether or not we will be using `exwm'.")
+
;; keep ~/.emacs.d clean
(use-package no-littering
:demand
@@ -394,7 +397,7 @@ For disabling the behaviour for certain buffers and/or modes."
;; time and battery in mode-line
(use-feature time
- :disabled
+ :if b/exwm-p
:demand
:config
(display-time-mode)
@@ -403,7 +406,7 @@ For disabling the behaviour for certain buffers and/or modes."
(display-time-format "%a %b %-e, %-l:%M%P"))
(use-feature battery
- :disabled
+ :if b/exwm-p
:demand
:config
(display-battery-mode)
@@ -568,7 +571,7 @@ For disabling the behaviour for certain buffers and/or modes."
;;; Essential packages
(use-package exwm
- :disabled
+ :if b/exwm-p
:demand
:config
;; make class name the buffer name, truncating beyond 60 characters
@@ -764,18 +767,7 @@ around if needed."
:config
(exwm-randr-enable)
:custom
- (exwm-randr-workspace-monitor-plist '(1 "VGA-1"))
- :hook
- (exwm-randr-screen-change . (lambda ()
- (let ((xrandr
- (string-join
- '("xrandr"
- "--output VGA-1"
- "--same-as LVDS-1"
- "--auto")
- " ")))
- (start-process-shell-command
- "xrandr" nil xrandr)))))
+ (exwm-randr-workspace-monitor-plist '(1 "VGA-1")))
(use-feature exwm-systemtray
:demand
@@ -1572,7 +1564,9 @@ This function is intended for use with `ivy-ignore-buffers'."
(load-theme 'tangomod t)
(sml/apply-theme 'tangomod)
(font-lock-remove-keywords
- 'org-mode b/org-mode-font-lock-keywords))
+ 'org-mode b/org-mode-font-lock-keywords)
+ (when (featurep 'exwm-systemtray)
+ (exwm-systemtray--refresh)))
(defun b/lights-off ()
"Go dark."
@@ -1581,7 +1575,9 @@ This function is intended for use with `ivy-ignore-buffers'."
(load-theme 'doom-one t)
(sml/apply-theme 'automatic)
(font-lock-add-keywords
- 'org-mode b/org-mode-font-lock-keywords t))
+ 'org-mode b/org-mode-font-lock-keywords t)
+ (when (featurep 'exwm-systemtray)
+ (exwm-systemtray--refresh)))
(bind-keys
("C-c t d" . b/lights-off)