diff options
-rw-r--r-- | custom/jao-custom-blog.el | 2 | ||||
-rw-r--r-- | init.el | 35 |
2 files changed, 17 insertions, 20 deletions
diff --git a/custom/jao-custom-blog.el b/custom/jao-custom-blog.el index 201aed6..6ae4544 100644 --- a/custom/jao-custom-blog.el +++ b/custom/jao-custom-blog.el @@ -156,7 +156,7 @@ (when (y-or-n-p "Update date? ") (goto-char (point-min)) (when (re-search-forward "^#\\+date: " nil t) - (let ((kill-whole-line nil)) (kill-line)) + (delete-line) (insert (format-time-string "<%Y-%m-%d %H:%M>")) (save-buffer)))) @@ -895,7 +895,7 @@ (interactive "P") (jao-buffer-same-mode nil nil (and pop #'pop-to-buffer))) -(global-set-key (kbd "C-x C-b") #'jao-buffer-same-mode-cmd) +(global-set-key (kbd "C-c C-b") #'jao-buffer-same-mode-cmd) ;;;; projects (use-package project :demand t) @@ -2402,8 +2402,8 @@ (require 'haskell) (diminish 'interactive-haskell-mode " λ") -(diminish haskell-doc-mode) -(diminish haskell-decl-scan-mode) +(diminish 'haskell-doc-mode) +(diminish 'haskell-decl-scan-mode) (jao-define-attached-buffer "\\*hoogle\\*.*") (jao-define-attached-buffer '(major-mode . haskell-interactive-mode) 0.33) @@ -2836,15 +2836,16 @@ (use-package jao-mpris :demand t) -(defalias 'jao-streaming-lyrics #'jao-mpris-lyrics) -(defalias 'jao-streaming-toggle #'jao-mpris-play-pause) -(defalias 'jao-streaming-next #'jao-mpris-next) -(defalias 'jao-streaming-prev #'jao-mpris-previous) -(defalias 'jao-streaming-current #'jao-mpris-show-osd) -(defalias 'jao-streaming-seek #'jao-mpris-seek) -(defalias 'jao-streaming-seek-back #'jao-mpris-seek-back) -(defalias 'jao-streaming-volume #'jao-mpris-vol) -(defalias 'jao-streaming-volume-down #'jao-mpris-vol-down) +(defun jao-mpris-setup-aliases () + (defalias 'jao-streaming-lyrics #'jao-mpris-lyrics) + (defalias 'jao-streaming-toggle #'jao-mpris-play-pause) + (defalias 'jao-streaming-next #'jao-mpris-next) + (defalias 'jao-streaming-prev #'jao-mpris-previous) + (defalias 'jao-streaming-current #'jao-mpris-show-osd) + (defalias 'jao-streaming-seek #'jao-mpris-seek) + (defalias 'jao-streaming-seek-back #'jao-mpris-seek-back) + (defalias 'jao-streaming-volume #'jao-mpris-vol) + (defalias 'jao-streaming-volume-down #'jao-mpris-vol-down)) (jao-mpris-register "playerctld" :session (if jao-mode-line-in-minibuffer -10 70)) @@ -2939,13 +2940,9 @@ (defun jao-streaming-toggle-player () (interactive) (if jao-spt-on - (let ((player (completing-read "Player: " - '( "chromium" "mopidy" "firefox" - "spotify") - nil nil nil nil jao-mpris-player))) - (setq jao-mpris-player player) - (require 'jao-mpris) - (jao-mpris-setup-aliases)) + (progn (setq jao-mpris-player "playerctld") + (require 'jao-mpris) + (jao-mpris-setup-aliases)) (jao-spt-setup-aliases) (setq jao-mpris-player "spt")) (message "%s activated " |