Permalink
Browse files

Minor fixes; point initsplit at my copy

  • Loading branch information...
1 parent 85cab01 commit df31846396194c173e3482133d2dba350ff0299b @jwiegley committed Jun 17, 2012
Showing with 140 additions and 107 deletions.
  1. +1 −1 .gitmodules
  2. +11 −15 dot-org.el
  3. +127 −90 emacs.el
  4. +1 −1 lisp/initsplit
View
@@ -27,7 +27,7 @@
url = https://github.com/jwiegley/gnus-harvest.git
[submodule "lisp/initsplit"]
path = lisp/initsplit
- url = https://github.com/dabrahams/initsplit.git
+ url = https://github.com/jwiegley/initsplit.git
[submodule "lisp/muse"]
path = lisp/muse
url = https://github.com/jwiegley/muse.git
View
@@ -709,13 +709,13 @@ Summary: %s" product component version priority severity heading) ?\n ?\n)
(defun ,org-sym ()
(interactive)
(org-todo ,label))
- (define-key mode-specific-map [?x ,key] ',org-sym)
+ (bind-key (concat "C-c x " (char-to-string ,key)) ',org-sym)
(defun ,org-sym-no-logging ()
(interactive)
(let ((org-inhibit-logging t))
(org-todo ,label)))
- (define-key mode-specific-map [?x ,(upcase key)]
+ (bind-key (concat "C-c x " (char-to-string ,(upcase key)))
',org-sym-no-logging)
(defun ,org-agenda-sym ()
@@ -730,19 +730,14 @@ Summary: %s" product component version priority severity heading) ?\n ?\n)
(define-key org-todo-state-map [,(upcase key)]
',org-agenda-sym-no-logging)))))
-(define-key mode-specific-map [?x ?l] 'org-insert-dtp-link)
-(define-key mode-specific-map [?x ?L] 'org-set-dtp-link)
-
-(define-key mode-specific-map [?x ?m] 'org-insert-message-link)
-(define-key mode-specific-map [?x ?M] 'org-set-message-link)
-;;(define-key mode-specific-map [?x ?a] 'org-insert-apple-message-link)
-(define-key mode-specific-map [?x ?Y] 'org-set-message-sender)
-
-(define-key mode-specific-map [?x ?u] 'org-insert-url-link)
-(define-key mode-specific-map [?x ?U] 'org-set-url-link)
-
-(define-key mode-specific-map [?x ?f] 'org-insert-file-link)
-(define-key mode-specific-map [?x ?F] 'org-set-file-link)
+(bind-key "C-c x l" 'org-insert-dtp-link)
+(bind-key "C-c x L" 'org-set-dtp-link)
+(bind-key "C-c x m" 'org-insert-message-link)
+(bind-key "C-c x M" 'org-set-message-link)
+(bind-key "C-c x u" 'org-insert-url-link)
+(bind-key "C-c x U" 'org-set-url-link)
+(bind-key "C-c x f" 'org-insert-file-link)
+(bind-key "C-c x F" 'org-set-file-link)
(autoload 'ledger-test-create "ldg-test" nil t)
(autoload 'ledger-test-run "ldg-test" nil t)
@@ -756,6 +751,7 @@ Summary: %s" product component version priority severity heading) ?\n ?\n)
(org-defkey org-mode-map
[(control ?c) (control ?x) ?@] 'visible-mode)
+(defvar my-org-expand-map)
(define-prefix-command 'my-org-expand-map)
(define-key org-mode-map [(control ?c) (control ?e)] 'my-org-expand-map)
View
217 emacs.el
@@ -79,17 +79,43 @@
;;;_ , Enable disabled commands
-(put 'downcase-region 'disabled nil) ; Let upcasing work
+(put 'downcase-region 'disabled nil) ; Let downcasing work
(put 'erase-buffer 'disabled nil)
(put 'eval-expression 'disabled nil) ; Let ESC-ESC work
(put 'narrow-to-page 'disabled nil) ; Let narrowing work
(put 'narrow-to-region 'disabled nil) ; Let narrowing work
(put 'set-goal-column 'disabled nil)
-(put 'upcase-region 'disabled nil) ; Let downcasing work
+(put 'upcase-region 'disabled nil) ; Let upcasing work
;;;_. Keybindings
-;;;_ , C-?
+;; Main keymaps for personal bindings are:
+;;
+;; C-x <letter> primary map (has many defaults too)
+;; C-c <letter> secondary map (not just for mode-specific)
+;; C-. <letter> tertiary map
+;;
+;; M-g <letter> goto map
+;; M-s <letter> search map
+;; M-o <letter> markup map (even if only temporarily)
+;;
+;; C-<capital letter>
+;; M-<capital letter>
+;;
+;; A-<anything>
+;; M-A-<anything>
+;;
+;; Single-letter bindings still available:
+;; C- ,'";:?<>|!#$%^&*`~ <tab>
+;; M- ?#
+
+;;;_ , global-map
+
+;;;_ . C-?
+
+(defvar ctl-period-map)
+(define-prefix-command 'ctl-period-map)
+(bind-key "C-." 'ctl-period-map)
(bind-key* "<C-return>" 'other-window)
@@ -101,9 +127,95 @@
(bind-key "C-z" 'collapse-or-expand)
+;;;_ . M-?
+
+(bind-key "M-!" 'async-shell-command)
+(bind-key "M-/" 'dabbrev-expand)
+(bind-key "M-:" 'pp-eval-expression)
+(bind-key "M-'" 'insert-pair)
+(bind-key "M-\"" 'insert-pair)
+
+(defun align-code (beg end &optional arg)
+ (interactive "rP")
+ (if (null arg)
+ (align beg end)
+ (let ((end-mark (copy-marker end)))
+ (indent-region beg end-mark nil)
+ (align beg end-mark))))
+
+(bind-key "M-[" 'align-code)
+(bind-key "M-`" 'other-frame)
+
+(bind-key "M-j" 'delete-indentation-forward)
+(bind-key "M-J" 'delete-indentation)
+
+(bind-key "M-W" 'mark-word)
+
+(defun mark-line (&optional arg)
+ (interactive "p")
+ (beginning-of-line)
+ (let ((here (point)))
+ (dotimes (i arg)
+ (end-of-line))
+ (set-mark (point))
+ (goto-char here)))
+
+(bind-key "M-L" 'mark-line)
+
+(defun mark-sentence (&optional arg)
+ (interactive "P")
+ (backward-sentence)
+ (mark-end-of-sentence arg))
+
+(bind-key "M-S" 'mark-sentence)
+(bind-key "M-X" 'mark-sexp)
+(bind-key "M-H" 'mark-paragraph)
+(bind-key "M-D" 'mark-defun)
+
+(bind-key "M-g c" 'goto-char)
+(bind-key "M-g l" 'goto-line)
+
+(defun delete-indentation-forward ()
+ (interactive)
+ (delete-indentation t))
+
+(bind-key "M-s n" 'find-name-dired)
+(bind-key "M-s o" 'occur)
+
+(bind-key "A-M-w" 'copy-code-as-rtf)
+
+;;;_ . M-C-?
+
+(bind-key "<C-M-backspace>" 'backward-kill-sexp)
+
+(defun isearch-backward-other-window ()
+ (interactive)
+ (split-window-vertically)
+ (call-interactively 'isearch-backward))
+
+(bind-key "C-M-r" 'isearch-backward-other-window)
+
+(defun isearch-forward-other-window ()
+ (interactive)
+ (split-window-vertically)
+ (call-interactively 'isearch-forward))
+
+(bind-key "C-M-s" 'isearch-forward-other-window)
+
+;; Some further isearch bindings
+(bind-key "C-c" 'isearch-toggle-case-fold isearch-mode-map)
+(bind-key "C-t" 'isearch-toggle-regexp isearch-mode-map)
+(bind-key "C-^" 'isearch-edit-string isearch-mode-map)
+(bind-key "C-i" 'isearch-complete isearch-mode-map)
+
+;;;_ . A-?
+
+(define-key key-translation-map (kbd "A-TAB") (kbd "M-TAB"))
+
;;;_ , ctl-x-map
-(bind-key "C-x d" 'delete-whitespace-rectangle)
+;;;_ . C-x ?
+
(bind-key "C-x F" 'set-fill-column)
(bind-key "C-x t" 'toggle-truncate-lines)
@@ -417,12 +529,22 @@
(unfill-paragraph 1)
(forward-paragraph))))
+;;;_ , ctl-period-map
+
+;;;_ . C-. ?
+
+(bind-key "C-. d" 'delete-whitespace-rectangle)
+(bind-key "C-. r" 'indent-rigidly)
+
;;;_ , help-map
(defvar lisp-find-map)
(define-prefix-command 'lisp-find-map)
(bind-key "C-h e" 'lisp-find-map)
+
+;;;_ . C-h e ?
+
(bind-key "C-h e c" 'finder-commentary)
(bind-key "C-h e e" 'view-echo-area-messages)
(bind-key "C-h e f" 'find-function)
@@ -485,91 +607,6 @@
(bind-key "C-h e s" 'scratch)
(bind-key "C-h e v" 'find-variable)
-;;;_ , M-?
-
-(bind-key "M-!" 'async-shell-command)
-(bind-key "M-/" 'dabbrev-expand)
-(bind-key "M-:" 'pp-eval-expression)
-(bind-key "M-'" 'insert-pair)
-(bind-key "M-\"" 'insert-pair)
-
-(defun align-code (beg end &optional arg)
- (interactive "rP")
- (if (null arg)
- (align beg end)
- (let ((end-mark (copy-marker end)))
- (indent-region beg end-mark nil)
- (align beg end-mark))))
-
-(bind-key "M-[" 'align-code)
-(bind-key "M-`" 'other-frame)
-
-(bind-key "M-j" 'delete-indentation-forward)
-(bind-key "M-J" 'delete-indentation)
-
-(bind-key "M-W" 'mark-word)
-
-(defun mark-line (&optional arg)
- (interactive "p")
- (beginning-of-line)
- (let ((here (point)))
- (dotimes (i arg)
- (end-of-line))
- (set-mark (point))
- (goto-char here)))
-
-(bind-key "M-L" 'mark-line)
-
-(defun mark-sentence (&optional arg)
- (interactive "P")
- (backward-sentence)
- (mark-end-of-sentence arg))
-
-(bind-key "M-S" 'mark-sentence)
-(bind-key "M-X" 'mark-sexp)
-(bind-key "M-H" 'mark-paragraph)
-(bind-key "M-D" 'mark-defun)
-
-(bind-key "M-g c" 'goto-char)
-(bind-key "M-g l" 'goto-line)
-
-(defun delete-indentation-forward ()
- (interactive)
- (delete-indentation t))
-
-(bind-key "M-s n" 'find-name-dired)
-(bind-key "M-s o" 'occur)
-
-(bind-key "A-M-w" 'copy-code-as-rtf)
-
-;;;_ , M-C-?
-
-(bind-key "<C-M-backspace>" 'backward-kill-sexp)
-
-(defun isearch-backward-other-window ()
- (interactive)
- (split-window-vertically)
- (call-interactively 'isearch-backward))
-
-(bind-key "C-M-r" 'isearch-backward-other-window)
-
-(defun isearch-forward-other-window ()
- (interactive)
- (split-window-vertically)
- (call-interactively 'isearch-forward))
-
-(bind-key "C-M-s" 'isearch-forward-other-window)
-
-;; Some further isearch bindings
-(bind-key "C-c" 'isearch-toggle-case-fold isearch-mode-map)
-(bind-key "C-t" 'isearch-toggle-regexp isearch-mode-map)
-(bind-key "C-^" 'isearch-edit-string isearch-mode-map)
-(bind-key "C-i" 'isearch-complete isearch-mode-map)
-
-;;;_ , A-?
-
-(define-key key-translation-map (kbd "A-TAB") (kbd "M-TAB"))
-
;;;_. Packages
;;;_ , abbrev
@@ -2363,7 +2400,7 @@ end tell" account account start duration commodity (if cleared "true" "false")
;;;_ , springboard
(use-package springboard
- :bind ("C-." . springboard))
+ :bind ("C-x d" . springboard))
;;;_ , stopwatch

0 comments on commit df31846

Please sign in to comment.