summary refs log tree commit diff stats
path: root/emacs
diff options
context:
space:
mode:
authorAlan Pearce2017-05-21 11:14:56 +0200
committerAlan Pearce2017-05-21 11:14:56 +0200
commit97ac5faeee65e79d49bfa49d321f4d45772d6ec0 (patch)
tree00de7207f908fe2acfff88d519c01e761076c4be /emacs
parent8cb99ca85533e3252289e0ccb5ebe1dc8c98fa15 (diff)
parent80ff771431d668bff8c73461c606c8f1517752dd (diff)
downloaddotfiles-97ac5faeee65e79d49bfa49d321f4d45772d6ec0.tar.lz
dotfiles-97ac5faeee65e79d49bfa49d321f4d45772d6ec0.tar.zst
dotfiles-97ac5faeee65e79d49bfa49d321f4d45772d6ec0.zip
Merge remote-tracking branch 'origin/master'
Diffstat (limited to 'emacs')
-rw-r--r--emacs/.emacs.d/init.org44
1 files changed, 32 insertions, 12 deletions
diff --git a/emacs/.emacs.d/init.org b/emacs/.emacs.d/init.org
index 78c51e5..e0b928a 100644
--- a/emacs/.emacs.d/init.org
+++ b/emacs/.emacs.d/init.org
@@ -215,11 +215,12 @@ because I manage those in my [[file:~/projects/dotfiles/tag-xresources/xresource
     (cond
      ((eq window-system 'w32)
       (ap/set-fonts "Liberation Mono" 11 "Segoe UI" 11 t))
-     ((eq window-system 'ns)
+     ((or (eq window-system 'mac)
+          (eq window-system 'ns))
       (let ((displays (string-to-number (shell-command-to-string "system_profiler SPDisplaysDataType | grep \"Online: Yes\" | wc -l"))))
         (if (eq displays 1)
-            (ap/set-fonts "Lekton" 20 "Lucida Grande" 16 t)
-          (ap/set-fonts "Monaco" 14 "Lucida Grande" 14 nil 0.1))))
+            (ap/set-fonts "Monaco" 16 "Lucida Grande" 16 t 0.2)
+          (ap/set-fonts "Monoid" 12 "Helvetica Neue" 12 t 0.1))))
      ((and (eq window-system 'x)
            (not (getenv "windows")))
       (set-fontset-font "fontset-default" 'unicode (font-spec :name "Terminus" :size 14))
@@ -1706,15 +1707,6 @@ I can use this to keep a journal.  I should use it.
 #+END_SRC
 
 
-* Music
-Emacs actually supports playing music via mpd.
-
-#+BEGIN_SRC emacs-lisp
-(use-package mpc
-  :defer t
-  :config (progn
-            (setq mpc-browser-tags '(Genre Albumartist|Composer|Performer Album|Playlist))))
-#+END_SRC
 * Programming
 ** flycheck
 
@@ -2015,6 +2007,7 @@ an AST internally, so it can work with it almost like a lisp.
             (bind-key "M-g M-n" #'js2-next-error js2-mode-map)
             (bind-key "M-g M-p" #'ap/js2-prev-error js2-mode-map)
             (setq js2-basic-offset 2
+                  js-switch-indent-offset 2
                   js2-include-node-externs t
                   js2-highlight-level 1)))
 #+END_SRC
@@ -2182,6 +2175,33 @@ I derived a mode for twig, in order to use its =mode-hook=.
 (add-to-list 'auto-mode-alist '("\\.html\\.twig\\'" . twig-mode))
 #+END_SRC
 
+** Live coding
+
+Sometimes I might want to show off my emacs usage.
+
+#+BEGIN_SRC emacs-lisp
+(defun live-coding ()
+  (interactive)
+  (ap/set-fonts "SF Mono" 18 nil nil t 0.1)
+  (global-command-log-mode 1))
+
+(defun live-coding-stop ()
+  (interactive)
+  (ap/set-fonts-according-to-system)
+  (global-command-log-mode -1))
+#+END_SRC
+
+*** command-log-mode
+
+#+BEGIN_SRC emacs-lisp
+(use-package command-log-mode
+  :defines command-log-mode-key-binding-open-log
+  :init (progn
+          (setq command-log-mode-key-binding-open-log nil
+                command-log-mode-auto-show t
+                command-log-mode-is-global t)))
+#+END_SRC
+
 * Spelling
 
 #+BEGIN_SRC emacs-lisp