|
;;; 03-custom-binds --- A set of custom key bindings
|
|
|
|
;;; Commentary:
|
|
|
|
;;; Code:
|
|
|
|
(defvar my-term-shell "/bin/bash" "My preferred choice of shell.")
|
|
(defadvice ansi-term (before force-bash)
|
|
"Open an interactive ansi-terminal that defaults to bash."
|
|
(interactive (list my-term-shell)))
|
|
(ad-activate 'ansi-term)
|
|
|
|
;; Get shell env vars.
|
|
(let ((path (shell-command-to-string ". /Users/leviolson/.bashrc; echo -n $PATH")))
|
|
(setenv "PATH" (concat path ":/usr/local/bin"))
|
|
(setq exec-path
|
|
(append
|
|
(split-string-and-unquote (concat path ":/usr/local/bin") ":")
|
|
exec-path)))
|
|
|
|
(bind-key "<M-return>" 'eshell)
|
|
(bind-key "<M-S-return>" 'ansi-term)
|
|
(bind-key "C-c r" '(lambda () (interactive) (load-file user-init-file)))
|
|
|
|
(provide '03-custom-binds)
|
|
;;; 03-custom-binds.el ends here
|