From: Mark Wooding Date: Tue, 3 May 2016 16:27:17 +0000 (+0100) Subject: Merge remote-tracking branch 'origin' X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~mdw/git/profile/commitdiff_plain/d24eae26fe96001540a169eb467c4457e82f0b78?hp=580ac7ce11353166bdfa83283e6b51f282135dfe Merge remote-tracking branch 'origin' * origin: dot/ipython_config.py: Let's just have one of these for everywhere. --- diff --git a/dot/emacs b/dot/emacs index f6290cc..f8bd2e7 100644 --- a/dot/emacs +++ b/dot/emacs @@ -240,6 +240,7 @@ (member (md5 addr) '("8815c5583970856799c85a3ee0eb6a9f" ;work wiki spam "0b94ab4d25dacaa5ac07243a09c9e22e" ;work bug spam + "35fb1633379a1e4d4be3b139cae20111" ;work crucible spam )) (and (string-match "^news\\([0-9]+\\)@\\(.*\\)$" addr) (string= (md5 (match-string 2 addr)) @@ -312,8 +313,9 @@ truncate-lines t) (setq default-indicate-empty-lines t) (setq view-read-only t) -(setq whitespace-style - '(trailing space-before-tab space-after-tab empty indentation face)) +(setq whitespace-style '(trailing empty indentation face lines-tail + space-before-tab space-after-tab) + whitespace-line-column 77) (setq woman-use-own-frame nil ;Keep man pages somewhere sensible woman-fill-column 72) ;Right margin position. (setq diff-switches "-u" ;I like reading unified diffs diff --git a/dot/gnus.el b/dot/gnus.el index a8779d9..91d5d81 100644 --- a/dot/gnus.el +++ b/dot/gnus.el @@ -61,6 +61,12 @@ (setq mm-verify-option 'known mm-sign-option 'guided mm-decrypt-option 'never) +;; Tracking available groups. These should work for sane servers, but maybe +;; they'll need hacking in the local file. +(setq gnus-save-killed-list nil + gnus-check-bogus-newsgroups nil + gnus-read-active-file 'ask-server) + ;; Use one article buffer per group. (setq gnus-single-article-buffer nil) diff --git a/el/dot-emacs.el b/el/dot-emacs.el index a2989fe..d883666 100644 --- a/el/dot-emacs.el +++ b/el/dot-emacs.el @@ -370,27 +370,45 @@ (defadvice org-agenda-list (around mdw-preserve-links activate) (let ((mdw-diary-for-org-mode-p t)) ad-do-it)) -(defadvice diary-add-to-list (before mdw-trim-leading-space activate) +(defadvice diary-add-to-list (before mdw-trim-leading-space compile activate) "Trim leading space from the diary entry string." (save-match-data - (let ((str (ad-get-arg 1))) - (ad-set-arg 1 - (cond ((null str) nil) + (let ((str (ad-get-arg 1)) + (done nil) old) + (while (not done) + (setq old str) + (setq str (cond ((null str) nil) + ((string-match "\\(^\\|\n\\)[ \t]+" str) + (replace-match "\\1" nil nil str)) ((and mdw-diary-for-org-mode-p (string-match (concat - "^[ \t]*" + "\\(^\\|\n\\)" "\\(" diary-time-regexp "\\(-" diary-time-regexp "\\)?" - "\\)[ \t]+") + "\\)" + "\\(\t[ \t]*\\| [ \t]+\\)") str)) - (replace-match "\\1 " nil nil str)) - ((string-match "^[ \t]+" str) - (replace-match "" nil nil str)) + (replace-match "\\1\\2 " nil nil str)) ((and (not mdw-diary-for-org-mode-p) (string-match "\\[\\[[^][]*]\\[\\([^][]*\\)]]" str)) (replace-match "\\1" nil nil str)) - (t str)))))) + (t str))) + (if (equal str old) (setq done t))) + (ad-set-arg 1 str)))) + +(defadvice org-bbdb-anniversaries (after mdw-fixup-list compile activate) + "Return a string rather than a list." + (with-temp-buffer + (let ((anyp nil)) + (dolist (e (let ((ee ad-return-value)) + (if (atom ee) (list ee) ee))) + (when e + (when anyp (insert ?\n)) + (insert e) + (setq anyp t))) + (setq ad-return-value + (and anyp (buffer-string)))))) ;; Fighting with Org-mode's evil key maps. @@ -1219,6 +1237,9 @@ (mdw-define-face dired-perm-write (mdw-define-face trailing-whitespace (((class color)) :background "red") (t :inverse-video t)) +(mdw-define-face whitespace-line + (((class color)) :background "darkred") + (t :inverse-video :t)) (mdw-define-face mdw-punct-face (((type tty)) :foreground "yellow") (t :foreground "burlywood2")) (mdw-define-face mdw-number-face @@ -1335,6 +1356,12 @@ (mdw-define-face diff-context (mdw-define-face diff-refine-change (((class color) (type x)) :background "RoyalBlue4") (t :underline t)) +(mdw-define-face diff-refine-removed + (((class color) (type x)) :background "#500") + (t :underline t)) +(mdw-define-face diff-refine-added + (((class color) (type x)) :background "#050") + (t :underline t)) (mdw-define-face dylan-header-background (((class color) (type x)) :background "NavyBlue")