Permalink
Browse files

Various minor changes

  • Loading branch information...
1 parent b6a5b69 commit 918313b29ed181d138afae7ec8642b672f999c34 John Wiegley committed Jan 9, 2013
Showing with 177 additions and 59 deletions.
  1. +2 −2 gnus-settings.el
  2. +136 −30 init.el
  3. +12 −10 lisp/fetchmail-ctl.el
  4. +1 −1 lisp/haskell-config
  5. +2 −0 lisp/persian-johnw.el
  6. +5 −1 org-settings.el
  7. +17 −13 settings.el
  8. +1 −1 site-lisp/ghc-mod
  9. +1 −1 snippets/erc-mode/ftp
View

Large diffs are not rendered by default.

Oops, something went wrong.
View
166 init.el
@@ -253,6 +253,14 @@
(bind-key "C-x F" 'set-fill-column)
(bind-key "C-x t" 'toggle-truncate-lines)
+(defun toggle-transparency ()
+ (interactive)
+ (if (/= (cadr (frame-parameter nil 'alpha)) 100)
+ (set-frame-parameter nil 'alpha '(100 100))
+ (set-frame-parameter nil 'alpha '(85 50))))
+
+(bind-key "C-x T" 'toggle-transparency)
+
;;;_ . C-x C-?
(defun duplicate-line ()
@@ -1512,13 +1520,24 @@ iflipb-next-buffer or iflipb-previous-buffer this round."
(use-package dired
:defer t
+ :init
+ (progn
+ (defvar mark-files-cache (make-hash-table :test #'equal))
+
+ (defun mark-similar-versions (name)
+ (let ((pat name))
+ (if (string-match "^\\(.+?\\)-[0-9._-]+$" pat)
+ (setq pat (match-string 1 pat)))
+ (or (gethash pat mark-files-cache)
+ (ignore (puthash pat t mark-files-cache))))))
+
:config
(progn
(defun dired-package-initialize ()
(unless (featurep 'runner)
(use-package dired-x)
;; (use-package dired-async)
- (use-package dired-sort-map)
+ ;; (use-package dired-sort-map)
(use-package runner)
(use-package dired-details-hide
:commands dired-details-toggle)
@@ -1753,27 +1772,70 @@ The output appears in the buffer `*Async Shell Command*'."
erc-fill-column 88
erc-insert-timestamp-function 'erc-insert-timestamp-left)
- (set-input-method "Agda"))
+ (set-input-method "Agda")
+
+ (defun reset-erc-track-mode ()
+ (interactive)
+ (setq erc-modified-channels-alist nil)
+ (erc-modified-channels-update))
+
+ (bind-key "C-c r" 'reset-erc-track-mode))
(add-hook 'erc-mode-hook 'setup-irc-environment)
(defun irc ()
(interactive)
- (erc-tls :server "irc.freenode.net"
- :port 6697
- :nick "johnw"
- :password (funcall
- (plist-get
- (car (auth-source-search :host "irc.freenode.net"
- :user "johnw"
- :type 'netrc
- :port 6667))
- :secret)))
-
- (erc :server "irc.well-typed.com"
- :port 6665
- :nick "johnw")
+ (if (or t (quickping "192.168.9.135"))
+ (progn
+ (erc :server "192.168.9.135"
+ :port 6697
+ :nick "johnw"
+ :password (funcall
+ (plist-get
+ (car (auth-source-search :host "192.168.9.135"
+ :user "johnw/freenode"
+ :type 'netrc
+ :port 6697))
+ :secret)))
+ (erc :server "192.168.9.135"
+ :port 6697
+ :nick "johnw"
+ :password (funcall
+ (plist-get
+ (car (auth-source-search :host "192.168.9.135"
+ :user "johnw/welltyped"
+ :type 'netrc
+ :port 6697))
+ :secret)))
+ (erc :server "192.168.9.135"
+ :port 6697
+ :nick "johnw"
+ :password (funcall
+ (plist-get
+ (car (auth-source-search :host "192.168.9.135"
+ :user "johnw/oftc"
+ :type 'netrc
+ :port 6697))
+ :secret))))
+ (erc-tls :server "irc.freenode.net"
+ :port 6697
+ :nick "johnw"
+ :password (funcall
+ (plist-get
+ (car (auth-source-search :host "irc.freenode.net"
+ :user "johnw"
+ :type 'netrc
+ :port 6667))
+ :secret)))
+
+ (erc :server "irc.well-typed.com"
+ :port 6665
+ :nick "johnw"))
+
+ ;; (erc-tls :server "irc.oftc.net"
+ ;; :port 6697
+ ;; :nick "johnw")
)
(defun im ()
@@ -1868,7 +1930,51 @@ FORM => (eval FORM)."
(defun erc-cmd-DEOPME ()
"Deop myself from current channel."
- (erc-cmd-DEOP (format "%s" (erc-current-nick))))))
+ (erc-cmd-DEOP (format "%s" (erc-current-nick))))
+
+ (defun erc-cmd-UNTRACK (&optional target)
+ "Add TARGET to the list of target to be tracked."
+ (if target
+ (erc-with-server-buffer
+ (let ((untracked
+ (car (erc-member-ignore-case target erc-track-exclude))))
+ (if untracked
+ (erc-display-line
+ (erc-make-notice
+ (format "%s is not currently tracked!" target))
+ 'active)
+ (add-to-list 'erc-track-exclude target)
+ (erc-display-line
+ (erc-make-notice (format "Now not tracking %s" target))
+ 'active))))
+
+ (if (null erc-track-exclude)
+ (erc-display-line
+ (erc-make-notice "Untracked targets list is empty") 'active)
+
+ (erc-display-line (erc-make-notice "Untracked targets list:") 'active)
+ (mapc #'(lambda (item)
+ (erc-display-line (erc-make-notice item) 'active))
+ (erc-with-server-buffer erc-track-exclude))))
+ t)
+
+
+ (defun erc-cmd-TRACK (target)
+ "Remove TARGET of the list of targets which they should not be tracked.
+ If no TARGET argument is specified, list contents of `erc-track-exclude'."
+ (when target
+ (erc-with-server-buffer
+ (let ((tracked
+ (not (car (erc-member-ignore-case target erc-track-exclude)))))
+ (if tracked
+ (erc-display-line
+ (erc-make-notice (format "%s is currently tracked!" target))
+ 'active)
+ (setq erc-track-exclude (remove target erc-track-exclude))
+ (erc-display-line
+ (erc-make-notice (format "Now tracking %s" target))
+ 'active)))))
+ t)))
;;;_ , eshell
@@ -1993,9 +2099,11 @@ FORM => (eval FORM)."
(use-package grep-ed)
(grep-apply-setting 'grep-command "egrep -nH -e ")
- (grep-apply-setting
- 'grep-find-command
- '("find . -type f -print0 | xargs -P4 -0 egrep -nH -e " . 52))))
+ (if t
+ (grep-apply-setting 'grep-find-command '("gf -e " . 7))
+ (grep-apply-setting
+ 'grep-find-command
+ '("find . -type f -print0 | xargs -P4 -0 egrep -nH -e " . 52)))))
;;;_ , gtags
@@ -2339,7 +2447,7 @@ FORM => (eval FORM)."
(compose-region (match-beginning 1)
(match-end 1) ))))
("(\\|)" . 'esk-paren-face)
- ("(\\(ert-deftest\\)\\>[ '(]*\\(setf[ ]+\\sw+\\|\\sw+\\)?"
+ ("(\\(ert-deftest\\)\\>[ '(]*\\(setf[ ]+\\sw+\\|\\sw+\\)?"
(1 font-lock-keyword-face)
(2 font-lock-function-name-face
nil t)))))
@@ -2929,13 +3037,11 @@ FORM => (eval FORM)."
(whitespace-mode 1)
(unicode-tokens-use-shortcuts 0)))
(bind-key "M-RET" 'proof-goto-point coq-mode-map)
- (bind-key "<tab>" 'yas/expand-from-trigger-key coq-mode-map)))
-
- (defadvice proof-electric-terminator
- (around insert-newline-after-terminator activate)
- (save-excursion
- ad-do-it)
- (forward-char))))
+ (bind-key "<tab>" 'yas/expand-from-trigger-key coq-mode-map)
+ (bind-key "C-c C-p" (lambda ()
+ (interactive)
+ (proof-layout-windows)
+ (proof-prf)) coq-mode-map)))))
;;;_ , ps-print
@@ -3074,7 +3180,7 @@ FORM => (eval FORM)."
;;;_ , sage-mode
(use-package sage
- :load-path "/Applications/Misc/sage/data/emacs/"
+ :load-path "/Applications/Misc/sage/local/share/emacs/"
:init
(progn
(setq sage-command "/Applications/Misc/sage/sage")
@@ -3086,7 +3192,7 @@ FORM => (eval FORM)."
(add-hook 'sage-startup-after-prompt-hook 'sage-view)
;; You can use commands like
;; (add-hook 'sage-startup-after-prompt-hook 'sage-view-disable-inline-output)
- (add-hook 'sage-startup-after-prompt-hook 'sage-view-disable-inline-plots)
+ (add-hook 'sage-startup-after-prompt-hook 'sage-view-disable-inline-plots t)
;; to enable some combination of features
))
View
@@ -44,16 +44,17 @@
(throw 'proc-running proc)
(throw 'proc-running nil)))))))
-(defun start-fetchmail (&optional name &rest extra-args)
+(defun start-fetchmail (&optional name once &rest extra-args)
(interactive)
(let ((procname (or name "*fetchmail*")))
(unless (process-running-p procname)
(message "Starting Fetchmail...")
- (let ((buf (get-buffer-create procname)))
+ (let ((buf (get-buffer-create procname))
+ (args (copy-list extra-args)))
+ (unless once (nconc args '("-d" "900")))
(setq fetchmail-process
(apply #'start-process procname buf
- "/usr/local/bin/fetchmail" "-n" "-d" "900" "-N"
- extra-args)))
+ "/usr/local/bin/fetchmail" "-n" "-N" args)))
(message "Starting Fetchmail...done"))))
(defun safely-kill-process (name &optional signal verb)
@@ -73,14 +74,15 @@
(interactive)
(safely-kill-process "*fetchmail*")
(safely-kill-process "*fetchmail-lists*")
- (safely-kill-process "*fetchmail-spam*")
+ ;; (safely-kill-process "*fetchmail-spam*")
(safely-kill-process "*fetchnews*"))
(defun kick-fetchmail ()
(interactive)
(safely-kill-process "*fetchmail*" 'SIGUSR1 "Kicking")
(safely-kill-process "*fetchmail-lists*" 'SIGUSR1 "Kicking")
- (safely-kill-process "*fetchmail-spam*" 'SIGUSR1 "Kicking"))
+ ;; (safely-kill-process "*fetchmail-spam*" 'SIGUSR1 "Kicking")
+ )
(defun get-buffer-or-call-func (name func)
(let ((buf (get-buffer name)))
@@ -98,15 +100,15 @@
"*fetchmail*"
(function
(lambda ()
- (start-fetchmail "*fetchmail*" "--idle")))))
+ (start-fetchmail "*fetchmail*" nil "--idle")))))
(fetchmail-lists-buf
(get-buffer-or-call-func
"*fetchmail-lists*"
(function
(lambda ()
(let ((process-environment (copy-alist process-environment)))
(setenv "FETCHMAILHOME" (expand-file-name "~/Messages/Newsdir"))
- (start-fetchmail "*fetchmail-lists*"
+ (start-fetchmail "*fetchmail-lists*" nil
"-f" (expand-file-name
"~/Messages/fetchmailrc.lists")))))))
(fetchmail-spam-buf
@@ -116,7 +118,7 @@
(lambda ()
(let ((process-environment (copy-alist process-environment)))
(setenv "FETCHMAILHOME" (expand-file-name "~/Messages/Maildir"))
- (start-fetchmail "*fetchmail-spam*"
+ (start-fetchmail "*fetchmail-spam*" t
"-f" (expand-file-name
"~/Messages/fetchmailrc.spam")))))))
(fetchnews-buf
@@ -128,7 +130,7 @@
(get-buffer-create "*fetchnews*")
(executable-find "fetchnews")
"-F" (expand-file-name "~/Messages/leafnode/config")
- "-vvv" "-n")))))
+ "-vvv")))))
(cur-buf (current-buffer)))
(delete-other-windows)
(flet ((switch-in-other-buffer
Submodule haskell-config updated 1 files
+71 −18 haskell-config.el
View
@@ -178,3 +178,5 @@
("\\0" ?0)
)
+
+(provide 'persian-johnw)
View
@@ -9,7 +9,7 @@
'(org-agenda-custom-commands (quote (("h" "Current Hotlist" tags "HOT&TODO=\"PROJECT\"" ((org-agenda-overriding-header "Current Hotlist"))) ("H" "Non-Hot Projects" tags "-HOT&TODO=\"PROJECT\"" ((org-agenda-overriding-header "Non-Hot Projects"))) ("A" "Priority #A tasks" agenda "" ((org-agenda-ndays 1) (org-agenda-overriding-header "Today's priority #A tasks: ") (org-agenda-skip-function (quote (org-agenda-skip-entry-if (quote notregexp) "\\=.*\\[#A\\]"))))) ("b" "Priority #A and #B tasks" agenda "" ((org-agenda-ndays 1) (org-agenda-overriding-header "Today's priority #A and #B tasks: ") (org-agenda-skip-function (quote (org-agenda-skip-entry-if (quote regexp) "\\=.*\\[#C\\]"))))) ("E" "Errands (next 7 days)" tags "Errand&TODO<>\"DONE\"&TODO<>\"CANCELED\"&STYLE<>\"habit\"&SCHEDULED<\"<+7d>\"" ((org-agenda-overriding-header "Errands (next 7 days)"))) ("Z" "Agenda (next 7 days)" agenda "" ((org-agenda-ndays 7) (org-agenda-overriding-header "Agenda (next 7 days)"))) ("r" "Uncategorized items" tags "CATEGORY=\"Inbox\"&LEVEL=2" ((org-agenda-overriding-header "Uncategorized items"))) ("W" "Waiting/delegated tasks" tags "TODO=\"WAITING\"|TODO=\"DELEGATED\"" ((org-agenda-overriding-header "Waiting/delegated tasks:") (org-agenda-sorting-strategy (quote (todo-state-up priority-down category-up))))) ("z" "Computer-related tasks" tags "AREA=\"Computer\"&TODO<>\"\"&TODO<>{DONE\\|CANCELED\\|NOTE\\|PROJECT}" ((org-agenda-files (quote ("~/Documents/Tasks/todo.txt"))) (org-agenda-overriding-header "Computer-related tasks: ") (org-agenda-skip-function (quote (org-agenda-skip-entry-if (quote scheduled) (quote deadline) (quote timestamp) (quote regexp) "\\* \\(DEFERRED\\|SOMEDAY\\)"))) (org-agenda-sorting-strategy (quote (priority-down))))) ("u" "Unscheduled tasks" tags "AREA<>{Work\\|Computer\\|Statements}&TODO<>\"\"&TODO<>{DONE\\|CANCELED\\|NOTE\\|PROJECT}" ((org-agenda-files (quote ("~/Documents/Tasks/todo.txt"))) (org-agenda-overriding-header "Unscheduled tasks: ") (org-agenda-skip-function (quote (org-agenda-skip-entry-if (quote scheduled) (quote deadline) (quote timestamp) (quote regexp) "\\* \\(DEFERRED\\|SOMEDAY\\)"))) (org-agenda-sorting-strategy (quote (priority-down))))) ("U" "Deferred tasks" tags "TODO=\"DEFERRED\"" ((org-agenda-files (quote ("~/Documents/Tasks/todo.txt"))) (org-agenda-overriding-header "Deferred tasks:"))) ("Y" "Someday tasks" tags "TODO=\"SOMEDAY\"" ((org-agenda-overriding-header "Someday tasks:"))) ("w" "Unscheduled work-related tasks" tags "AREA=\"Work\"&TODO<>\"\"&TODO<>{DONE\\|CANCELED\\|NOTE\\|PROJECT}" ((org-agenda-overriding-header "Unscheduled work-related tasks") (org-agenda-files (quote ("~/Documents/Tasks/todo.txt"))) (org-agenda-sorting-strategy (quote (todo-state-up priority-down category-up))) (org-agenda-skip-function (quote (org-agenda-skip-entry-if (quote scheduled) (quote deadline) (quote timestamp)))))) ("v" "All work-related tasks" tags "AREA=\"Work\"&TODO<>\"\"&TODO<>{DONE\\|CANCELED\\|NOTE\\|PROJECT}" ((org-agenda-overriding-header "Work-related tasks") (org-agenda-files (quote ("~/Documents/Tasks/todo.txt"))) (org-agenda-sorting-strategy (quote (category-up priority-down todo-state-up alpha-up))) (org-agenda-skip-function (quote (org-agenda-skip-entry-if (quote regexp) "\\* \\(DEFERRED\\|SOMEDAY\\)"))))) ("l" "Ledger tasks" tags-todo "TODO<>{SOMEDAY\\|DEFERRED}" ((org-agenda-files (quote ("~/src/ledger/plan/TODO"))) (org-agenda-overriding-header "Ledger tasks:") (org-agenda-sorting-strategy (quote (todo-state-up priority-down category-up))) (org-agenda-skip-function (quote (org-agenda-skip-entry-if (quote regexp) "\\=.*\\[#C\\]"))))) ("L" "Ledger tasks not in Bugzilla" tags "TODO<>{DONE\\|TESTED\\|CLOSED\\|CANCELED\\|WONTFIX\\|WORKSFORME\\|INVALID\\|DUPLICATE\\|NOTE}&LEVEL=2" ((org-agenda-files (quote ("~/src/ledger/plan/TODO"))) (org-agenda-overriding-header "Ledger tasks:") (org-agenda-sorting-strategy (quote (todo-state-up priority-down category-up))) (org-agenda-skip-function (quote (org-agenda-skip-entry-if (quote regexp) "[^(]#[0-9]+\\]"))))) ("G" "Ledger tasks (all)" alltodo "" ((org-agenda-files (quote ("~/src/ledger/plan/TODO"))) (org-agenda-overriding-header "Ledger tasks:") (org-agenda-sorting-strategy (quote (todo-state-up priority-down category-up))))) ("N" "Ledger tasks (all, alphabetical)" alltodo "" ((org-agenda-files (quote ("~/src/ledger/plan/TODO"))) (org-agenda-overriding-header "Ledger tasks, alphabetical:") (org-agenda-sorting-strategy (quote (alpha-up))))) ("n" "Notes" tags "TODO=\"NOTE\"" ((org-agenda-files (quote ("~/Documents/Tasks/archive-2009.txt" "~/Documents/Tasks/archive-2010.txt" "~/Documents/Tasks/archive-2011.txt" "~/Documents/Tasks/archive.txt" "~/Documents/Tasks/notes.txt"))) (org-agenda-overriding-header "Notes") (org-agenda-sorting-strategy (quote (time-down))))) ("S" "Assembly Action Items" tags-todo "TODO<>\"PROJECT\"" ((org-agenda-files (quote ("~/Documents/Tasks/assembly.txt"))) (org-agenda-overriding-header "Assembly Action Items") (org-agenda-sorting-strategy (quote (alpha-up time-up))))))))
'(org-agenda-deadline-leaders (quote ("!D!: " "D%02d: ")))
'(org-agenda-default-appointment-duration 60)
- '(org-agenda-files (quote ("~/Documents/Tasks/todo.txt" "~/Documents/Tasks/assembly.txt" "~/src/ledger/plan/TODO")))
+ '(org-agenda-files (quote ("~/src/vps/INSTALL.org" "~/Documents/Tasks/todo.txt" "~/Documents/Tasks/assembly.txt" "~/src/ledger/plan/TODO")))
'(org-agenda-fontify-priorities t)
'(org-agenda-include-diary t)
'(org-agenda-log-mode-items (quote (closed clock state)))
@@ -65,6 +65,7 @@ SCHEDULED: %t
[PACKAGES]" ("\\section{%s}" . "\\section*{%s}") ("\\subsection{%s}" . "\\subsection*{%s}") ("\\subsubsection{%s}" . "\\subsubsection*{%s}") ("\\paragraph{%s}" . "\\paragraph*{%s}") ("\\subparagraph{%s}" . "\\subparagraph*{%s}")) ("report" "\\documentclass[11pt]{report}" ("\\part{%s}" . "\\part*{%s}") ("\\chapter{%s}" . "\\chapter*{%s}") ("\\section{%s}" . "\\section*{%s}") ("\\subsection{%s}" . "\\subsection*{%s}") ("\\subsubsection{%s}" . "\\subsubsection*{%s}")) ("book" "\\documentclass[11pt]{book}" ("\\part{%s}" . "\\part*{%s}") ("\\chapter{%s}" . "\\chapter*{%s}") ("\\section{%s}" . "\\section*{%s}") ("\\subsection{%s}" . "\\subsection*{%s}") ("\\subsubsection{%s}" . "\\subsubsection*{%s}")) ("beamer" "\\documentclass{beamer}" org-beamer-sectioning))))
'(org-extend-today-until 8)
'(org-fast-tag-selection-single-key (quote expert))
+ '(org-fontify-done-headline t)
'(org-footnote-section nil)
'(org-habit-preceding-days 42)
'(org-habit-today-glyph 45)
@@ -97,6 +98,8 @@ SCHEDULED: %t
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
+ '(org-agenda-done ((t (:foreground "ForestGreen"))))
+ '(org-done ((t (:foreground "ForestGreen" :weight bold))))
'(org-habit-alert-face ((((background light)) (:background "#f5f946"))))
'(org-habit-alert-future-face ((((background light)) (:background "#fafca9"))))
'(org-habit-clear-face ((((background light)) (:background "#8270f9"))))
@@ -105,5 +108,6 @@ SCHEDULED: %t
'(org-habit-overdue-future-face ((((background light)) (:background "#fc9590"))))
'(org-habit-ready-face ((((background light)) (:background "#4df946"))))
'(org-habit-ready-future-face ((((background light)) (:background "#acfca9"))))
+ '(org-headline-done ((t (:foreground "RosyBrown" :strike-through t))))
'(org-scheduled ((((class color) (min-colors 88) (background light)) nil)))
'(org-upcoming-deadline ((((class color) (min-colors 88) (background light)) (:foreground "Brown")))))
Oops, something went wrong.

0 comments on commit 918313b

Please sign in to comment.