projects
/
~bandali
/
configs
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
2a2c4c5
)
* .local/bin/change-theme: Only call emacsclient there is an emacs process.
author
Amin Bandali
<bandali@kelar.org>
Sat, 7 May 2022 19:10:27 +0000
(15:10 -0400)
committer
Amin Bandali
<bandali@kelar.org>
Fri, 20 May 2022 02:19:59 +0000
(22:19 -0400)
.local/bin/change-theme
patch
|
blob
|
blame
|
history
diff --git
a/.local/bin/change-theme
b/.local/bin/change-theme
index
5d997cd
..
7b20bde
100755
(executable)
--- a/
.local/bin/change-theme
+++ b/
.local/bin/change-theme
@@
-20,7
+20,9
@@
printf "*.foreground: $fg\n*.background: $bg" | xrdb -override
printf "*VT100*foreground: $fg\n*VT100*background: $bg" | xrdb -override
# emacs
printf "*VT100*foreground: $fg\n*VT100*background: $bg" | xrdb -override
# emacs
-emacsclient -ue "(set-face-attribute 'default nil :foreground \"$fg\" :background \"$bg\")"
+if [ "$(pgrep -u $USER emacs)" ]; then
+ emacsclient -ue "(set-face-attribute 'default nil :foreground \"$fg\" :background \"$bg\")"
+fi
# terminals
for term in /dev/pts/*; do
if [ -w "$term" ]; then
# terminals
for term in /dev/pts/*; do
if [ -w "$term" ]; then