.emacs.d/init.el
This commit is contained in:
parent
802607545b
commit
f7f9f0dcd0
1 changed files with 25 additions and 19 deletions
|
@ -121,8 +121,8 @@ actual account name."
|
|||
|
||||
(defmacro oni:email (user at host dot com)
|
||||
"Turn arguments into an email address.
|
||||
The resulting email address will look like: USER@HOST.COM, AT and DOT are
|
||||
intentionally being skipped."
|
||||
The resulting email address will look like: USER@HOST.COM, AT and
|
||||
DOT are intentionally being skipped."
|
||||
(concat (symbol-name user) "@" (symbol-name host) "."
|
||||
(symbol-name com)))
|
||||
|
||||
|
@ -606,6 +606,14 @@ insert at the end of the region and at the beginning."
|
|||
(setq dir (replace-match "\\1/" nil nil dir)))
|
||||
dir)
|
||||
|
||||
(defun oni:start-emms ()
|
||||
"Check to see if the function `emms' exists, if not call
|
||||
`emms-player-mpd-connect' and assume that will have loaded it."
|
||||
(interactive)
|
||||
(unless (fboundp 'emms)
|
||||
(emms-player-mpd-connect))
|
||||
(emms))
|
||||
|
||||
(defun oni:term-mode-func ()
|
||||
"Function for `term-mode-hook'."
|
||||
(setq truncate-lines nil))
|
||||
|
@ -614,18 +622,19 @@ insert at the end of the region and at the beginning."
|
|||
"Function for `texinfo-mode-hook'."
|
||||
(auto-fill-mode))
|
||||
|
||||
(defun oni:view-mail ()
|
||||
(defun oni:view-mail (inbox)
|
||||
"Show a menu with all mailbox options from `oni:mailbox-map'
|
||||
for easy selection."
|
||||
(interactive)
|
||||
(interactive
|
||||
(list (progn
|
||||
(require 'tmm)
|
||||
(let* ((tmm-completion-prompt "Choose a mailbox\n")
|
||||
(inbox (tmm-prompt oni:mailbox-map)))
|
||||
(let ((tmm-completion-prompt "Choose a mailbox\n"))
|
||||
(tmm-prompt oni:mailbox-map)))))
|
||||
(if inbox
|
||||
(progn
|
||||
(require 'mu4e)
|
||||
(funcall (intern (concat "oni:" inbox "-mailbox")))
|
||||
(mu4e)))))
|
||||
(mu4e))))
|
||||
|
||||
(defun oni:write-file-func ()
|
||||
"Function for `write-file-hooks'."
|
||||
|
@ -681,11 +690,6 @@ for easy selection."
|
|||
(eval-after-load "info"
|
||||
'(require 'info+))
|
||||
|
||||
(eval-after-load "lua-mode"
|
||||
`(progn
|
||||
(modify-syntax-entry ?- "< 12" lua-mode-syntax-table)
|
||||
(modify-syntax-entry ?\n ">" lua-mode-syntax-table)))
|
||||
|
||||
(eval-after-load "mu4e"
|
||||
'(add-to-list
|
||||
'org-capture-templates
|
||||
|
@ -809,7 +813,7 @@ for easy selection."
|
|||
(vertical-scroll-bars . nil)
|
||||
(menu-bar-lines . nil)
|
||||
(tool-bar-lines . nil)
|
||||
(font . "LiberationMono:pixelsize=16")
|
||||
(font . "osaka_unicode:pixelsize=18")
|
||||
(left-fringe . 0)))
|
||||
(setq emms-source-file-default-directory "/mnt/music/")
|
||||
(setq erc-autojoin-channels-alist
|
||||
|
@ -937,6 +941,7 @@ for easy selection."
|
|||
("gnu" . "http://elpa.gnu.org/packages/")
|
||||
("marmalade" . "http://marmalade-repo.org/packages/")))
|
||||
(setq package-load-list '((htmlize "1.39")
|
||||
(lua-mode "20111107")
|
||||
all))
|
||||
(setq php-function-call-face 'font-lock-function-name-face)
|
||||
(setq php-mode-force-pear t)
|
||||
|
@ -953,6 +958,7 @@ for easy selection."
|
|||
(setq scroll-conservatively 101)
|
||||
(setq send-mail-function 'smtpmail-send-it)
|
||||
(setq sendmail-program "/usr/bin/msmtp")
|
||||
(setq smex-key-advice-ignore-menu-bar t)
|
||||
(setq smex-save-file "~/.emacs.d/smex-items")
|
||||
(setq special-display-buffer-names '("*Sauron*"))
|
||||
(setq special-display-frame-alist '((minibuffer . nil)
|
||||
|
@ -1007,7 +1013,7 @@ for easy selection."
|
|||
(global-set-key (kbd "<XF86AudioStop>") 'emms-stop)
|
||||
(global-set-key (kbd "<XF86HomePage>") 'oni:raise-scratch)
|
||||
(global-set-key (kbd "<XF86Mail>") 'oni:view-mail)
|
||||
(global-set-key (kbd "<XF86Tools>") 'emms)
|
||||
(global-set-key (kbd "<XF86Tools>") 'oni:start-emms)
|
||||
(global-set-key (kbd "<f5>") 'oni:reload-buffer)
|
||||
(global-set-key (kbd "<f6>") 'jabber-switch-to-roster-buffer)
|
||||
(global-set-key (kbd "<f7>") 'magit-status)
|
||||
|
|
Loading…
Reference in a new issue