ソースを参照

Drop my own shell hack thing for a package.

cray
Mitch Tishmack 11年前
コミット
1226f40c51
1個のファイルの変更11行の追加20行の削除
  1. +11
    -20
      emacs/.emacs.d/emacs.org

+ 11
- 20
emacs/.emacs.d/emacs.org ファイルの表示

@@ -107,26 +107,6 @@ Make it easier to determine what os we're running on.
"Am I running under linux?")
#+END_SRC

***** Mac OS X Gui emacs PATH setup

This is here because if gui emacs gets started say from Finder, one can
end up with missing certain things that aren't in the default PATH.

The strategy is fire off a $SHELL and have it echo the PATH it has and
then parse that to setup emacs exec-path.

For now we restrict this only to OSX. It may be more generally useful
however.

#+BEGIN_SRC emacs-lisp
(defun set-exec-path-from-shell-PATH ()
(let ((path-from-shell
(shell-command-to-string "$SHELL -i -c 'echo $PATH'")))
(setenv "PATH" path-from-shell)
(setq exec-path (split-string path-from-shell path-separator))))

(if on-osx (set-exec-path-from-shell-PATH))
#+END_SRC
*** disable pointless startup stuff

Like the startup screen and the echo hooey.
@@ -494,6 +474,17 @@ Ah Fonts. Let me specify them for gui emacs.

All the packages I use.

*** exec-path-from-shell

Turns out that someone wrote this exact thing already. Yay get to drop my own crap.

#+BEGIN_SRC emacs-lisp
(use-package exec-path-from-shell
:ensure t
:init (if on-osx (exec-path-from-shell-initialize))
)
#+END_SRC

*** expand-region

#+BEGIN_SRC emacs-lisp


読み込み中…
キャンセル
保存