From 3d10340f69651608362bacbe91cc10a90bdf4de3 Mon Sep 17 00:00:00 2001 From: Case Duckworth Date: Wed, 1 Sep 2021 08:37:17 -0500 Subject: Add titlecase --- init.el | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'init.el') diff --git a/init.el b/init.el index e3fee58..0eb32db 100644 --- a/init.el +++ b/init.el @@ -976,11 +976,16 @@ like a dumbass." (setq read-extended-command-predicate #'command-completion-default-include-p)) + (defvar case-map (make-sparse-keymap) + "A keymap for setting case in various ways.") + (global-set-key (kbd "C-c c") case-map) + (:global "M-=" count-words "C-w" kill-region-or-backward-word - "C-c c" capitalize-dwim - "C-c u" upcase-dwim - "C-c l" downcase-dwim + "C-c c c" capitalize-dwim + "C-c c t" titlecase-dwim + "C-c c u" upcase-dwim + "C-c c l" downcase-dwim "C-c d" acdw/insert-iso-date "M-`" nil) @@ -999,6 +1004,7 @@ like a dumbass." (defalias 'backward-word-with-case 'backward-word "Alias for `backward-word for use in `case-repeat-map'.") + ;; XXX: this isn't repeating correctly ... (defvar case-repeat-map (let ((map (make-sparse-keymap))) (define-key map "c" #'capitalize-word) -- cgit 1.4.1-21-gabe81 From 362338b0cb47d146538367b3e9dbc8d7d2ce2cc3 Mon Sep 17 00:00:00 2001 From: Case Duckworth Date: Wed, 1 Sep 2021 08:37:37 -0500 Subject: Remove dired-async--modeline-mode It causes an error with simple-modeline. --- init.el | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'init.el') diff --git a/init.el b/init.el index 0eb32db..50ae388 100644 --- a/init.el +++ b/init.el @@ -1061,7 +1061,11 @@ like a dumbass." (setup (:straight async) (autoload 'dired-async-mode "dired-async.el" nil t) - (dired-async-mode +1)) + (dired-async-mode +1) + (add-hook 'dired-mode + (defun dired@disable-dired-async-mode-line () + (autoload 'dired-async--modeline-mode "dired-async.el" nil t) + (dired-async--modeline-mode -1)))) (setup (:straight ace-link) (ace-link-setup-default) -- cgit 1.4.1-21-gabe81 From f2d51752a88ae226ad3c0a95e8bd17354af5ec2d Mon Sep 17 00:00:00 2001 From: Case Duckworth Date: Wed, 1 Sep 2021 08:42:07 -0500 Subject: Add requirements for affe --- init.el | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'init.el') diff --git a/init.el b/init.el index 50ae388..3e631fc 100644 --- a/init.el +++ b/init.el @@ -1051,7 +1051,9 @@ like a dumbass." (indent-region (point-min) (point-max)))))) (setup (:straight-if affe - (executable-find "rg")) + (and (or (executable-find "fd") + (executable-find "find")) + (executable-find "rg"))) ;; Keys are bound in `acdw/sensible-grep' and `acdw/sensible-find' (defun affe-orderless-regexp-compiler (input _type) (setq input (orderless-pattern-compiler input)) -- cgit 1.4.1-21-gabe81 From 9bbc43a4557adcfafe75c3970c16c5102bfdf195 Mon Sep 17 00:00:00 2001 From: Case Duckworth Date: Wed, 1 Sep 2021 17:14:44 -0500 Subject: Add acdw/fetch-password and circe network configuration --- init.el | 19 +++++++++++++++++-- lisp/acdw.el | 13 ++++++++++++- 2 files changed, 29 insertions(+), 3 deletions(-) (limited to 'init.el') diff --git a/init.el b/init.el index 3e631fc..d56c33d 100644 --- a/init.el +++ b/init.el @@ -1119,9 +1119,24 @@ like a dumbass." (setq acdw-irc/post-my-nick "-> ") - (setq circe-default-part-message "See You, Space Cowpokes . . ." + (setq circe-default-nick "acdw" + circe-default-part-message "See You, Space Cowpokes . . ." circe-highlight-nick-type 'all - ;; circe-network-options in private.el + circe-network-options + (("Libera Chat" + :channels ("#emacs" "#systemcrafters" "##webpals") + :sasl-username "acdw" + :sasl-password ,(acdw/fetch-password :host "libera.chat")) + ("Tilde Chat" + :channels ("#meta" "#bread" "#dadjokes" "#team") + :host "irc.tilde.chat" :port 6697 :use-tls t + :sasl-username "acdw" + :sasl-password ,(acdw/fetch-password :host "tilde.chat")) + ("Casa" + :channels ("#basement") + :host "m455.casa" :port 6697 :use-tls t + :sasl-username "acdw" + :sasl-password ,(acdw/fetch-password :host "m455.casa"))) circe-reduce-lurker-spam t circe-server-auto-join-default-type :after-auth) diff --git a/lisp/acdw.el b/lisp/acdw.el index f23ca0e..796c2f1 100644 --- a/lisp/acdw.el +++ b/lisp/acdw.el @@ -579,7 +579,18 @@ It's called 'require-private' for historical reasons." (switch-to-buffer nil) (other-window (or arg 1)))) - + +;;; Auth-sources +;; https://github.com/emacs-circe/circe/wiki/Configuration +(defun acdw/fetch-password (&rest params) + (require 'auth-source) + (let ((match (car (apply #'auth-source-search params)))) + (if match + (let ((secret (plist-get match :secret))) + (if (functionp secret) + (funcall secret) + secret)) + (warn "Password not found for %S" params)))) (provide 'acdw) ;;; acdw.el ends here -- cgit 1.4.1-21-gabe81 From 2b74eb7995a53e6e9d3631904fdaddbe67f7e723 Mon Sep 17 00:00:00 2001 From: Case Duckworth Date: Wed, 1 Sep 2021 17:15:20 -0500 Subject: Add elfeed --- init.el | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'init.el') diff --git a/init.el b/init.el index d56c33d..5a9d9e9 100644 --- a/init.el +++ b/init.el @@ -1362,6 +1362,23 @@ like a dumbass." :repo "duckwork/electric-cursor")) (electric-cursor-mode +1)) +(setup (:straight elfeed + elfeed-protocol) + (:option elfeed-use-curl t + elfeed-feeds `(("fever+https://acdw@mf.acdw.net" + :api-url "https://mf.acdw.net/fever/" + :password ,(acdw/fetch-password + :host "mf.acdw.net")))) + + (elfeed-protocol-enable) + + (add-hook 'elfeed-show-mode-hook + (defun elfeed-show@setup () + (olivetti-mode +1))) + + ;; see https://irreal.org/blog/?p=8885 + ) + (setup (:straight (elpher :host nil :repo "git://thelambdalab.xyz/elpher.git")) (:option elpher-ipv4-always t -- cgit 1.4.1-21-gabe81