From 659fc238ff78b67319fe44b7ec06b189d22ca251 Mon Sep 17 00:00:00 2001 From: Ian Kelling Date: Sun, 21 Jan 2018 21:57:27 -0500 Subject: [PATCH] various fixes, new keyboard --- my-init.org | 357 ++++++++++++++++++++++++++++------------------------ 1 file changed, 192 insertions(+), 165 deletions(-) diff --git a/my-init.org b/my-init.org index e893ebe..6dcb7f1 100644 --- a/my-init.org +++ b/my-init.org @@ -160,7 +160,9 @@ find a recently dated file in ~/.emacs.d/auto-save-list/, and see the files list If it is different, emacs will give a message about recovering it when you open it. - +* TODO see if there are more cool functions in sh-script +like sh-cd-here, and bind that to a key +* TODO assign a key to append-next-kill * TODO keybinds to remember keys worth memorizing @@ -485,7 +487,7 @@ if all else fails, edit the abbrev file (setq explicit-shell-file-name "bash") ;; readline-complete says to add this line. -;; however, it messes up my procfs directory tracking hook +;; however, it up my procfs directory tracking hook ;; because get-process doesn't notice the child shell. ;; instead, I've removed export EMACS=t from ;; comint-exec-1 (the function which initially sets it) @@ -595,6 +597,8 @@ I need this function here, where INSIDE_EMACS is replaced with RLC_INSIDE_EMACS. (not (string= (buffer-file-name) "*draft*")) (buffer-modified-p) (not (org-src-edit-buffer-p))) + ;; serial is incremented on each save, so let's do a bit less of them + (not (derived-mode-p 'dns-mode)) (setq my-auto-save-last last) (let (message-log-max) ;; a bit of a hack to partially suppress the constant saving in the echo area @@ -735,8 +739,7 @@ seems they are created ;; recommended by gnus, ;; but seems like it could be good to have set for other stuff -(setq user-full-name "Ian Kelling" - user-mail-address "ian@iankelling.org") +(setq user-full-name "Ian Kelling") ;; general email setting? recommended by mu4e (setq message-kill-buffer-on-exit t) @@ -844,7 +847,7 @@ interesting light themes ;; theme packages i tried then removed: ;; ignored ones that didn't use the new theme engine -;;66 packages (zenburn-theme-2.1, zen-and-art-theme-1.0.1, waher-theme-20130917.7, ujelly-theme-1.0.35, twilight-theme-1.0.0, twilight-bright-theme-20130605.143, twilight-anti-bright-theme-20120713.316, tronesque-theme-1.3, tron-theme-12, toxi-theme-0.1.0, tommyh-theme-1.2, tango-2-theme-1.0.0, sunny-day-theme-20131203.1250, sublime-themes-20140117.323, subatomic-theme-20131011.1048, soothe-theme-0.3.16, soft-morning-theme-20131211.1342, soft-charcoal-theme-20130924.1206, sea-before-storm-theme-0.3, purple-haze-theme-20130929.1751, phoenix-dark-pink-theme-20130905.941, phoenix-dark-mono-theme-20130306.1215, pastels-on-dark-theme-0.3, obsidian-theme-20130920.937, nzenburn-theme-20130513, noctilux-theme-20131019.31, mustang-theme-20130920.939, monokai-theme-0.0.10, molokai-theme-20130828.0, late-night-theme-0.0, jujube-theme-0.1, ir-black-theme-20130302.2355, gruvbox-theme-20131229.1458, gruber-darker-theme-0.6, grandshell-theme-20140118.1003, github-theme-0.0.3, gandalf-theme-0.1, flatland-theme-20131204.858, django-theme-20131022.202, deep-thought-theme-0.1.1, dakrone-theme-20131212.1159, colorsarenice-theme-20131128.1106, color-theme-wombat+-0.0.2, color-theme-wombat-0.0.1, color-theme-twilight-0.1, color-theme-tango-0.0.2, color-theme-solarized-20120301, color-theme-sanityinc-solarized-2.25, color-theme-railscasts-0.0.2, color-theme-monokai-0.0.5, color-theme-molokai-0.1, color-theme-ir-black-1.0.1, color-theme-heroku-1.0.0, color-theme-github-0.0.3, color-theme-eclipse-0.0.2, color-theme-dpaste-0.0.1, color-theme-dawn-night-1.0, color-theme-colorful-obsolescence-0.0.1, color-theme-cobalt-0.0.2, color-theme-20080305.34, clues-theme-20130908.801, busybee-theme-20130920.942, bubbleberry-theme-0.1.2, assemblage-theme-20130715.621, anti-zenburn-theme-20140104.1542, ample-zen-theme-0.2) +;;66 packages (zenburn-theme-2.1, zen-and-art-theme-1.0.1, waher-theme-20130917.7, ujelly-theme-1.0.35, twilight-theme-1.0.0, twilight-bright-theme-20130605.143, twilight-anti-bright-theme-20120713.316, tronesque-theme-1.3, tron-theme-12, toxi-theme-0.1.0, tommyh-theme-1.2, tango-2-theme-1.0.0, sunny-day-theme-20131203.1250, sublime-themes-20140117.323, subatomic-theme-20131011.1048, soothe-theme-0.3.16, soft-morning-theme-20131211.1342, soft-charcoal-theme-20130924.1206, sea-before-storm-theme-0.3, purple-haze-theme-20130929.1751, phoenix-dark-pink-theme-20130905.941, phoenix-dark-mono-theme-20130306.1215, pastels-on-dark-theme-0.3, obsidian-theme-20130920.937, nzenburn-theme-20130513, noctilux-theme-20131019.31, mustang-theme-20130920.939, monokai-theme-0.0.10, molokai-theme-20130828.0, late-night-theme-0.0, jujube-theme-0.1, ir-black-theme-20130302.2355, gruvbox-theme-20131229.1458, gruber-darker-theme-0.6, grandshell-theme-20140118.1003, github-theme-0.0.3, gandalf-theme-0.1, flatland-theme-20131204.858, django-theme-20131022.202, deep-thought-theme-0.1.1, dakrone-theme-20131212.1159, colorsarenice-theme-20131128.1106, color-theme-wombat+-0.0.2, color-theme-wombat-0.0.1, color-theme-twilight-0.1, color-theme-tango-0.0.2, color-theme-solarized-20120301, color-theme-sanityinc-solarized-2.25, color-theme-railscasts-0.0.2, color-theme-monokai-0.0.5, color-theme-molokai-0.1, color-theme-ir-black-1.0.1, color-theme-heroku-1.0.0, color-theme-github-0.0.3, color-theme-eclipse-0.0.2, color-theme-dpaste-0.0.1, color-theme-dawn-night-1.0, color-theme-colorful-obsolescence-0.0.1, color-theme-cobalt-0.0.2, color-theme-20080305.34, clues-theme-20130908.801, busybee-theme-20130920.942, bubbleberry-theme-0.1.2, mblage-theme-20130715.621, anti-zenburn-theme-20140104.1542, ample-zen-theme-0.2) @@ -947,18 +950,14 @@ has a list of folders which i'd rather not publish, so it's config is archived. #+begin_src emacs-lisp ;;(add-to-list 'load-path "/usr/local/share/emacs/site-lisp/mu4e") (require 'mu4e) + +;; (setq mu4e-headers-results-limit 2000) + (setq send-mail-function (quote sendmail-send-it) ;; common to gnus also - mu4e-maildir "/m/4e" ;; use the standard imap folders mu4e-sent-folder "/Sent" mu4e-drafts-folder "/Drafts" mu4e-trash-folder "/Trash" - ;; standard imap folder is /Archive, but I've set this to /Junk, - ;; because I don't manually archive individual messages, and mu4e - ;; is lacking a button to move to the spam folder "Junk", and I - ;; want one to train spamassassin better. Note: It calls - ;; archiving "refiling", so it's bound to r. - mu4e-refile-folder "/Junk" ;; reindex new mail this often in seconds ;; show addresses instead of just names mu4e-view-show-addresses t @@ -966,8 +965,8 @@ has a list of folders which i'd rather not publish, so it's config is archived. mu4e-confirm-quit nil mu4e-headers-leave-behavior 'apply ;; dont ask, do whatever was marked mu4e-headers-fields (delq (assoc :mailing-list mu4e-headers-fields) mu4e-headers-fields) - ;; a bit faster than the default 500. trying out the default for now - ;;mu4e-headers-results-limit 80 + ;; default 500. + mu4e-headers-results-limit 1000 ;; looking up the list of maildirs when doing jo from summary ;; can take a few seconds if we have a ton of messages. @@ -989,24 +988,109 @@ has a list of folders which i'd rather not publish, so it's config is archived. ;; inspired by mu4e info manual, search for mu4e-compose-pre-hook. (load "/p/c/mu4e.el") +(defun my-decrypt () + ;; use for decrypting in mu4e + (interactive) + (beginning-of-buffer) + (when (search-forward "-----BEGIN PGP MESSAGE-----" nil t) + (read-only-mode 0) + (let ((start (match-beginning 0)) + (end (search-forward "-----END PGP MESSAGE-----" nil t))) + (shell-command-on-region start end "gpg -dq" nil t shell-command-default-error-buffer t) + ))) +(add-hook 'mu4e-view-mode-hook 'my-decrypt) + +(defun mu-set-from-name (regexes) + "If we find an address matching regex, then set that address as the to, +and whatever was used" + (when mu4e-compose-parent-message + (let ((found nil)) + (while (and regexes (not found)) + (setq re (car regexes) + regexes (cdr regexes) + found (mu4e-message-contact-field-matches + mu4e-compose-parent-message :to re))) + (when found (setq user-mail-address (cdr found) + user-full-name (car found))) + found))) +(defun mu-set-from (regexes) + "If we find an address matching regex, then set that address as the to, +and Ian Kelling as the name" + (when mu4e-compose-parent-message + (let ((found nil)) + (while (and regexes (not found)) + (setq re (car regexes) + regexes (cdr regexes) + found (cdr (mu4e-message-contact-field-matches + mu4e-compose-parent-message :to re)))) + (when found (setq user-mail-address found + user-full-name "Ian Kelling")) + found))) + + +(defun my-mu4e-to-fsf () + "inspired by mu4e info manual, search for mu4e-compose-pre-hook." + (cond + ((mu-set-from '("iank@fsf.org" + "iank@gnu.org"))) + ((setq user-mail-address "iank@fsf.org" + user-full-name "Ian Kelling")))) + + +;; on first run mkdir -p /nocow/user/.mufsf; mu index --maildir=/nocow/user/fsfmd +(defun mu-exit-wait () + (interactive) + (let ((wait (= 0 (call-process "/bin/pidof" nil nil nil "mu")))) + (mu4e-quit) + ;; without sleep, we get database locked by another process error when hitting u + ;; if another mu was running. + (when wait (sleep-for 0 300)))) +(defun fsf-mu4e () + (interactive) + (unless (equal mu4e-maildir "/nocow/user/fsfmd") (mu-exit-wait)) + (setq + ;; fsf monitor is smaller + mu4e-headers-visible-lines 15 + mu4e-maildir "/nocow/user/fsfmd" + mu4e-refile-folder "/Spam" + mu4e-get-mail-command "/a/bin/distro-setup/fsf-get-mail" + user-mail-address "iank@fsf.org" + mail-signature " + +-- +Ian Kelling | Senior Systems Administrator, Free Software Foundation +GPG Key: B125 F60B 7B28 7FF6 A2B7 DF8F 170A F0E2 9542 95DF +https://fsf.org | https://gnu.org +" + + mu4e-user-mail-address-list '("iank@fsf.org" + "iank@gnu.org") + mu4e-maildir-shortcuts + '( ("/INBOX" . ?i) + ("/sysadmin" . ?a) + ("/sec" . ?x) + ("/rtcc" . ?c) + ("/Drafts" . ?d) + ("/Sent" . ?s) + ) + ) ;; end setq + (call-process "/a/exe/lnf" nil nil nil "-T" "/nocow/user/.mufsf" (concat (getenv "HOME") "/.mu")) + (add-hook 'mu4e-compose-pre-hook 'my-mu4e-to-fsf) + (remove-hook 'mu4e-compose-pre-hook 'my-mu4e-to) + (mu4e)) ;; end defun fsf-mu4e + + ;; it's implemented in mu4e, but not in the actions list for ;; some reason. (add-to-list 'mu4e-view-actions '("browser view" . mu4e-action-view-in-browser) t) -(setq mu4e-maildir-shortcuts - '( ("/INBOX" . ?i) - ("/github" . ?g) - ("/zroe" . ?z) - ("/Drafts" . ?d) - ("/Sent" . ?d) - )) ;; normally, you would add to this, but we want to ;; modify unread messages. the first 4 are defined by default. (setq mu4e-bookmarks `( ,(make-mu4e-bookmark :name "Unread messages" - :query "flag:unread AND NOT flag:trashed AND NOT maildir:/Junk AND NOT maildir:/fwfw" + :query "flag:unread AND NOT flag:trashed AND NOT maildir:/Junk AND NOT maildir:/fwfw AND NOT maildir:/log" :key ?u) ,(make-mu4e-bookmark :name "Today's messages" @@ -1502,50 +1586,10 @@ disabled, as I haven't used it in a long time. I think it was good for learning good info http://www.emacswiki.org/emacs/GnusTutorial good info http://www.emacs.uniyar.ac.ru/doc/em24h/emacs183.htm -searching / accessing old mailing list messages: -http://wiki.list.org/display/DOC/How+do+I+make+the+archives+searchable -3 options suggested. nabble is very good, and you can even reply directly from their web interface with your own email -address. -google with site:example.com/archive works -However, it has the downside of relying on a 3rd party running unreleased software. -mail-archive.com and gmane.org search do not work. - -Some lists mirror to a newsgroup via gmane, and then mirror the newsgroup via a google group, which has good search -ability, and you can post via the newsgroup. - -Downsides of nabble/google. Doesn't integrate with normal email programs, and lock in. They store and show you what you -have and haven't read, what messages you've sent, etc. migrating that data to a normal mail program is undocumented and - unsupported. - -mailmans normal public archives are a bit obfuscated, but there is also a "private" archive, available to subscribers, -which is not obfuscated, and can be easily imported to your local email program. -you have to sub and log in to the web interfact to access it, and then the url is unpublished, but follows a format, -which is documented in a few places around the web like -https://mail.python.org/pipermail/mailman-users/2005-September/046757.html -its form is: -https://lists.fedorahosted.org/mailman/private/hyperkitty-devel.mbox/hyperkitty-devel.mbox -http://www.example.com/mailman/private/.mbox/.mbox -if you copy the url after logging in, and pass it to this function, it will print the transformed url -lurl() { local x="${1#*/options/}"; x="${x%%/*}.mbox"; echo "${1%/mailman/*}/mailman/private/$x/$x"; } - -Then you can download that url. Actually downloading the url is something firefox doesn't make the easiest out of the box. - Here are some options: -- paste in the url bar, the save the page -as a file after it loads. -- use downthemall extension or similar and paste the url in it. -- put it in an html page as -a link (or a small javascript program which will display input as a link), then right click and save as. -wget won't work because you need to have (i assume) the authorization cookie mailman gives your browser - -people have written various tools to de-obfuscate the normal public archives and sometimes import them to a mail -program. It seems they were not aware of the private archive. However, these tools are probably still useful to automate -things. None of them has a lot of usage, so I decided it was not worth the risk of hitting bugs vs doing a few extra clicks. - -this was the most interesting one I found within a few minutes of googling. -https://github.com/wcdolphin/mailman-downloader - -Once you have an mbox file, there are rather straightforward ways to get it into any mail program, but I will cover -gnus, which I use and is a bit tricky. + +After downloading mailing list archives, once you have an mbox file, +there are rather straightforward ways to get it into any mail program, +but I will cover gnus, which I use and is a bit tricky. gnus has a native search (limited, too slow for body text searches), and external search engine integration. gnus manual recommends converting to maildir for searching local mail, but importing lots of maildir messages to gnus @@ -2040,6 +2084,12 @@ currently makes emacs hang a bunch. dunno why. just using eclipse instead * modes with little configuration needed #+begin_src emacs-lisp +(setq org-caldav-url "https://cal.iankelling.org" +org-caldav-calendar-id "ian" +org-caldav-inbox "/p/cal.org") +;;(org-caldav-sync) + + ;;(require 'dtrt-indent) ;;(setq dtrt-indent-mode t) @@ -2047,9 +2097,20 @@ currently makes emacs hang a bunch. dunno why. just using eclipse instead (load-file "/a/h/iank-mod.el") -(add-to-list 'load-path "/a/opt/ws-butler") +;; from when i was running my own patches +;;(add-to-list 'load-path "/a/opt/ws-butler") (require 'ws-butler) +;; todo: I think this is broken, it keeps collapsing the last line +;; for empty messages. + +;; the main problem is when it deletes the blank line at the end +;; of a message with an empty body. but I might also +;; be pasting whitespace significant things in here, so +;; just don't do anything. +;; todo: propose this upstream +(add-to-list 'ws-butler-global-exempt-modes 'message-mode) + (ws-butler-global-mode) @@ -2484,6 +2545,8 @@ Go to the next directory based on where the cursor is." * mode line #+begin_src emacs-lisp +;; make window title be the buffer name +(setq frame-title-format "%b") ; ----------------------------- ; fixing up the mode line @@ -2551,12 +2614,12 @@ Go to the next directory based on where the cursor is." (force-mode-line-update))) -(add-hook 'after-change-major-mode-hook (lambda () - -(setq mode-line-mule-info nil -mode-line-position nil -mode-line-modes nil))) ; todo, make only flymake status show up +(defun my-after-change-major-mode-hook () + (setq mode-line-mule-info nil + minor-mode-alist nil + mode-line-position nil)) ; todo, make only flymake status show up +(add-hook 'after-change-major-mode-hook 'my-after-change-major-mode-hook) #+end_src * mouse related @@ -3066,10 +3129,10 @@ clicking on info links ;; todo, generally fix org mode keys ;; todo, org-mark-element, unbdind from M-h, bind to mark defun key -(org-babel-do-load-languages - 'org-babel-load-languages - '((emacs-lisp . t) - (sh . t))) +;(org-babel-do-load-languages +; 'org-babel-load-languages +; '((emacs-lisp . t) +; (sh . t))) ;; make shell work like interactive bash shell (setq org-babel-default-header-args:sh @@ -3129,7 +3192,7 @@ clicking on info links (defun my-org-confirm-babel-evaluate (lang body) (not (or (string= (buffer-file-name) "/a/t.org") - (string= (buffer-file-name) "/home/ian/.emacs.d/my-init.org") + (string= (buffer-file-name) "/home/iank/.emacs.d/my-init.org") ))) (setq org-confirm-babel-evaluate 'my-org-confirm-babel-evaluate) @@ -3548,6 +3611,35 @@ these colors were better for dark theme #+RESULTS: : t +* zrc +#+begin_src emacs-lisp +(require 'znc) +;; from https://www.emacswiki.org/emacs/ErcSound +(defun erc-my-privmsg-sound (proc parsed) + (let* ((tgt (car (erc-response.command-args parsed))) + (privp (erc-current-nick-p tgt))) + (and + privp + (start-process-shell-command "ignoreme" nil "mpv --no-terminal --vo=null --volume=25 /a/bin/data/bird.mp3") + ;; We must return nil. See help for `erc-server-PRIVMSG-functions' + nil))) +(add-hook 'erc-server-PRIVMSG-functions + 'erc-my-privmsg-sound) + +(defun erc-sound-if-not-server (match-type nickuserhost msg) + (unless (string-match "Server:[0-9]+" nickuserhost) + (start-process-shell-command "ignoreme" nil "mpv --no-terminal --vo=null /a/bin/data/bird.mp3"))) +(add-hook 'erc-text-matched-hook 'erc-sound-if-not-server) + +(erc-track-mode 1) + (setq + ;; consider invisible frames to be unseen. seems like an obvious default + erc-track-visibility 'visible + ;; switch to buffer where i've been mentioned, etc instead of oldest + erc-track-switch-direction 'importance) + +#+end_src + * key binds. keep at end of file this should come at the end because it depends on key maps being @@ -3832,86 +3924,15 @@ discard message notmuch advance to next message/thread ** readline / bash / .inputrc -*** M-0-9] -bash digit-argument - -removed drill from all these because I'm using emacs for shell now -*** C-2] -terminal X paste -*** C-3] -terminal open file manager -*** C-q] -bash exchange-point-and-mark - -*** C-M-q] -quoted insert -*** C-w] - bash kill-region -*** C-e] - bash yank-last-arg -*** C-r - bash history-search-backward -*** C-t] - shell-expand-line, expand like bash does u hit enter -*** C-a] - bash comment-line -*** C-s] - bash yank-nth-arg - yank $1 of last argument, or nth if prefixed with a digit argument -*** C-d] - bash undo -*** C-f] -bash menu-complete -*** C-g] - bash edit-and-execute-command -*** C-z -*** C-x - emacs hard to rebind - looks like it actually wouldn't be that hard. - possibly take the output from bind -p, make all those keys undefined. -*** C-c - quit/cancel -*** C-v - yank, aka paste -*** C-M-v - yank-pop -*** C-b] - bash menu-complete-backward -*** tab -completion -*** C-tab] -terminal find -*** C-left/right] - forward/backward-word - -*** C-u] - bash backward-kill-word -*** C-i] -terminal find up -[ terminal crap, duplicate of tab ] -*** C-o] - bash operate-and-get-next, submit and bring up next item in history -*** C-p] -bash dabbrev-expand, - complete historical command names -*** C-h - terminal incompatible junk -*** C-k] - bash kill-line, to end of line -*** C-l] - bash clear screen -*** C-m] +*** C-m [--------] #+begin_src emacs-lisp (add-hook 'comint-mode-hook (lambda () (define-key comint-mode-map "\C-m" nil))) - #+end_src -*** C-space] -bash set mark -*** C-delete] - bash delete word +terminal crap, duplicate of enter + ** isearch *** C-w paste word/char under cursor into isearch @@ -3936,9 +3957,11 @@ isearch-occur (isearch-toggle-regexp) (cond (isearch-regexp (global-set-key (kbd "C-r") 'isearch-backward-regexp) + (define-key global-map (kbd "") 'isearch-forward-regexp) (define-key global-map (kbd "") 'isearch-forward-regexp)) (t (global-set-key (kbd "C-r") 'isearch-backward) + (define-key global-map (kbd "") 'isearch-forward) (define-key global-map (kbd "") 'isearch-forward)))) (define-key isearch-mode-map (kbd "M-r") 'my-isearch-toggle-regexp) #+end_src @@ -4025,8 +4048,10 @@ isearch-forward #+begin_src emacs-lisp ;; explained in http://stackoverflow.com/questions/7411920/how-to-bind-search-and-search-repeat-to-c-f-in-emacs (global-set-key (kbd "") 'isearch-forward) +(global-set-key (kbd "") 'isearch-forward) (define-key isearch-mode-map "\t" nil) (define-key isearch-mode-map (kbd "") 'isearch-repeat-forward) +(define-key isearch-mode-map (kbd "") 'isearch-repeat-forward) ;; get rid of the standard completion binding, always use auto-complete ;; this didn't work very well ;;(global-set-key (kbd "TAB") 'auto-complete) @@ -4275,6 +4300,7 @@ modes like org-mode which have their own yank function." shell #+begin_src emacs-lisp (global-set-key (kbd "") 'shell-wrap) +(global-set-key (kbd "") 'shell-wrap) #+end_src *** s-right arrow previous-buffer @@ -4724,9 +4750,12 @@ macro end / call (global-set-key (kbd "C-M-a") 'kmacro-end-or-call-macro) (add-hook 'perl-mode-hook (lambda () (define-key perl-mode-map (kbd "C-M-a") nil))) (add-hook 'LaTeX-mode-hook (lambda () (define-key LaTeX-mode-map (kbd "C-M-a") nil))) +(add-hook 'c++-mode-hook + (lambda () (define-key c++-mode-map (kbd "C-M-a") nil))) (add-hook 'c-mode-hook (lambda () (define-key c-mode-map (kbd "C-M-a") nil))) + #+end_src *** C-S-a *** C-s @@ -4836,9 +4865,9 @@ kill-region (global-set-key (kbd "C-s") 'kill-region) #+end_src *** M-x] -append-next-kill +smex #+begin_src emacs-lisp -(global-set-key (kbd "M-x") 'append-next-kill) +(global-set-key (kbd "M-x") 'smex) #+end_src *** C-M-x] cut-to-register @@ -5000,7 +5029,8 @@ keyboard-yank-primary (let ((mouse-yank-at-point t)) (mouse-yank-primary nil))) ;; paste selection -(global-set-key (kbd "C-)") 'keyboard-yank-primary) +(global-set-key (kbd "C-)") 'keyboard-yank-primary) ;; kinesis binding +(global-set-key (kbd "") 'keyboard-yank-primary) #+end_src *** M-right-arrow *** C-M-right-arrow @@ -5317,11 +5347,13 @@ copy-buffer-file-name (defun copy-buffer-file-name () (interactive) - (kill-new - (cond - ((derived-mode-p 'mu4e-view-mode) (mu4e-message-field-at-point :path)) - (t buffer-file-name)) - )) + (let ((name (cond + ((derived-mode-p 'mu4e-view-mode) (mu4e-message-field-at-point :path)) + (t buffer-file-name)) + )) + (kill-new name) + (message name))) + (global-set-key (kbd "C-M-/") 'copy-buffer-file-name) @@ -5535,13 +5567,8 @@ org cycle todo / toggle comint motion (define-key map (kbd "") 'my-comint-next-input) (goto-char (point-max))))) -(defun ian-sign-email () - (interactive) - (insert "Ian Kelling -https://iankelling.org")) - (eval-after-load "message" - '(define-key message-mode-map (kbd "C-t") 'ian-sign-email)) + '(define-key message-mode-map (kbd "C-t") 'mail-signature)) #+end_src Thanks for the update. I will be enjoying it. -- 2.30.2