X-Git-Url: https://git.distorted.org.uk/~mdw/profile/blobdiff_plain/449874b395eab9f16ff7fc94e9cc7e204b71c6cc..0630988acc7864483d8f6ed96f0ff1971ddb4db6:/dot/emacs diff --git a/dot/emacs b/dot/emacs index 7208737..ff4843f 100644 --- a/dot/emacs +++ b/dot/emacs @@ -177,6 +177,11 @@ (setq calc-settings-file "~/.emacs-calc") (load calc-settings-file) +;; Saving window-configuration state. + +(or mdw-fast-startup + (winner-mode 1)) + ;; Some mail and news configuration. (setq mail-from-style 'angles @@ -201,7 +206,7 @@ (setq mail-user-agent 'message-user-agent read-mail-command 'gnus) -(setq message-signature-separator "^-- \\(\\|\\[mdw\\]\\)$" +(setq message-signature-separator "^-- \\(\\[mdw\\]\\)?$" message-yank-prefix "> " message-yank-cited-prefix "> " message-send-mail-function 'message-send-mail-with-sendmail @@ -233,19 +238,25 @@ (lambda () (let ((group gnus-newsgroup-name)) (and (string-match "^nn\\(imap\\|folder\\)\\+" group) - (not (string-match ":\\(crap\\|spam\\|lists\\|corpus\\)\\." + (not (string-match (concat ":" "\\(" "\\(" "crap" + "\\|" "spam" + "\\|" "lists" + "\\|" "corpus" + "\\)" "\\." + "\\|" "Junk Email$" + "\\)") group))))) bbdb-user-mail-names (concat "^" "\\(" "\\(mdw\\|markw\\|root\\|postmaster\\)" - "\\([-+][^@]*\\|\\)" + "\\([-+][^@]*\\)?" "@\\(\\(dist\\|esc\\)orted\\.org\\.uk\\|odin\\.gg\\)" "\\|" "\\(" "\\(mdw\\|mwooding\\)" "\\(\\+[^@]*\\)?" "\\|" "0" "\\(mdw\\|mwooding\\)" "k\\.[^@]*" "\\)" "@" "\\(chiark\\|slimy\\|coriolis\\)\\.greenend\\.org\\.uk" - "\\|" "distorted\\.mdw@g\\(\\|oogle\\)mail.com" + "\\|" "distorted\\.mdw@g\\(oogle\\)?mail.com" "\\|" "mwooding@\\(good\\|blackberry\\)\\.com" "\\|" "mark\\.wooding@trustonic\\.com" "\\)$") @@ -389,7 +400,7 @@ (setq Info-fontify-maximum-menu-size 100000) (setq set-mark-command-repeat-pop t) (setq password-cache-expiry nil) -(setq mouse-autoselect-window t) +(setq mouse-autoselect-window nil) (setq-default proced-filter 'all proced-sort 'user) (setq ispell-program-name "aspell-hack" @@ -422,6 +433,7 @@ (define-key outline-mode-prefix-map [?\C--] 'mdw-outline-collapse-all))) (define-key isearch-mode-map [?\C-?] 'isearch-del-char) +(define-key isearch-mode-map [backspace] 'isearch-del-char) (define-key isearch-mode-map [?\e ?\C-?] 'isearch-delete-char) (setq imenu-auto-rescan t @@ -587,6 +599,8 @@ (define-key mc-write-mode-map "\C-c/E" 'mc-encrypt-region) (add-hook 'text-mode-hook 'mc-install-write-mode)))) +(setq epa-pinentry-mode 'loopback) + ;;;-------------------------------------------------------------------------- ;;; Other common declarations. @@ -702,12 +716,17 @@ (global-set-key [?\C-c ?t ?s] 'timeclock-status-string) (global-set-key [?\C-c ?t ?t] 'gtags-find-tag-from-here) (global-set-key [?\C-c ?t ?w] 'timeclock-workday-remaining-string) + (global-set-key [?\C-c ?v ?f] 'view-file) + (global-set-key [?\C-c ?v ?i] 'vm-visit-imap-folder) + (global-set-key [?\C-c ?v ?m] 'vm-visit-folder) (global-set-key [?\C-c ?v ?v] 'mdw-auto-revert) (global-set-key [?\C-c ?w ?d] 'mdw-divvy-window) (global-set-key [?\C-c ?w ?h] 'windmove-left) (global-set-key [?\C-c ?w ?j] 'windmove-down) (global-set-key [?\C-c ?w ?k] 'windmove-up) (global-set-key [?\C-c ?w ?l] 'windmove-right) + (global-set-key [?\C-c ?w ?r] 'winner-redo) + (global-set-key [?\C-c ?w ?u] 'winner-undo) (global-set-key [?\C-c ?w ?w] 'mdw-set-frame-width) (global-set-key [?\C-c ?w up] 'windmove-up) (global-set-key [?\C-c ?w down] 'windmove-down) @@ -884,9 +903,9 @@ ((executable-find "sudo") "sudo") (t "su"))) (this-host (concat "\\`\\(localhost\\|" - (system-name) "\\|\\)\\'")) + (system-name) "\\)?\\'")) (this-user (concat "\\`\\(" (user-login-name) "\\|" - (user-real-login-name) "\\|\\)\\'"))) + (user-real-login-name) "\\)?\\'"))) (setq tramp-default-method-alist `((,this-host nil ,rootlyness) (nil ,this-user "ssh") @@ -931,7 +950,7 @@ (setq shell-prompt-pattern "^[^]#$%>»}\n]*\\([]#$%»}]\\|>>?\\) *") (setq comint-password-prompt-regexp (concat "\\(\\([Ee]nter \\|[Oo]ld \\|[Nn]ew \\|[a-zA-Z0-9_]*'s \\|^\\)" - "[Pp]assword\\|[Pp]ass ?phrase\\(\\| [-a-zA-Z0-9._]+\\)\\):") + "[Pp]assword\\|[Pp]ass ?phrase\\( [-a-zA-Z0-9._]+\\)?\\):") comint-file-name-chars "~/A-Za-z0-9+@:_.$#%,={}-" shell-file-name-chars comint-file-name-chars)