diff options
-rw-r--r-- | .config/bash/rc.d/emacs.sh | 1 | ||||
-rw-r--r-- | .config/emacs/init.el | 16 | ||||
l--------- | .config/systemd/user/default.target.wants/emacs-daemon.service | 2 | ||||
-rw-r--r-- | .config/systemd/user/x0vncserver@.service | 10 |
4 files changed, 26 insertions, 3 deletions
diff --git a/.config/bash/rc.d/emacs.sh b/.config/bash/rc.d/emacs.sh index 4a7b9b8..bb6454b 100644 --- a/.config/bash/rc.d/emacs.sh +++ b/.config/bash/rc.d/emacs.sh @@ -86,6 +86,7 @@ if [[ $TERM == eterm* ]]; then # Set the shell's X11 display (emacs -> shell) _emacs_set_shell_DISPLAY() { export DISPLAY=$(_emacs_unquote "$(_emacs_run "(cdr (assoc 'display (frame-parameters)))")") + [[ $DISPLAY != nil ]] || unset DISPLAY } ## Do those things ##################################################### diff --git a/.config/emacs/init.el b/.config/emacs/init.el index 246ea6a..fabe70e 100644 --- a/.config/emacs/init.el +++ b/.config/emacs/init.el @@ -117,6 +117,7 @@ page-break-lines ;; Major modes apel flim semi wanderlust + graphviz-dot-mode markdown-mode nginx-mode ;;nxhtml ; nxhtml is invasive, only enable if actively using @@ -128,8 +129,19 @@ (when (fboundp 'tool-bar-mode) (tool-bar-mode -1)) -(defadvice align-regexp (around lukeshu-align-with-spaces) - (let ((indent-tabs-mode nil)) ad-do-it)) +(defun align-regexp--use-spaces (orig-fun &rest args) + "Use spaces for alignment" + (let ((indent-tabs-mode nil)) + (apply orig-fun args))) +(advice-add 'align-regexp :around #'align-regexp--use-spaces) + +(defun sh-smie-sh-rules--fix (args) + "Replace :after \"then\" with :after \"if\" because Emacs 24 +sh-script.el is broken." + (if (equal args (list :after "then")) + (list :after "if") + args)) +(advice-add 'sh-smie-sh-rules :filter-args #'sh-smie-sh-rules--fix) (require 'go-mode-load nil t) diff --git a/.config/systemd/user/default.target.wants/emacs-daemon.service b/.config/systemd/user/default.target.wants/emacs-daemon.service index 106cf42..e3a3cc0 120000 --- a/.config/systemd/user/default.target.wants/emacs-daemon.service +++ b/.config/systemd/user/default.target.wants/emacs-daemon.service @@ -1 +1 @@ -/home/lukeshu-parabola/.config/systemd/user/emacs-daemon.service
\ No newline at end of file +../emacs-daemon.service
\ No newline at end of file diff --git a/.config/systemd/user/x0vncserver@.service b/.config/systemd/user/x0vncserver@.service new file mode 100644 index 0000000..99e897c --- /dev/null +++ b/.config/systemd/user/x0vncserver@.service @@ -0,0 +1,10 @@ +[Unit] +Description=VNC server for X displays + +[Service] +Type=simple +ExecStart=/bin/bash -l -c 'x0vncserver display=:%I PasswordFile="${HOME}/.vnc/passwd"' +Restart=always + +[Install] +WantedBy=default.target |