kyagi / shell-pop-el

shell-pop.el helps you to use shell easily on Emacs. Only one key action to work.
213 stars 21 forks source link

Support login shell #44

Closed mankoff closed 9 years ago

mankoff commented 9 years ago

(setq shell-pop-term-shell "/usr/local/bin/bash -l") doesn't seem to source my ~/.bash_profile. Is there some other way to get shell-pop to use a login shell?

syohex commented 9 years ago

I suppose you can write own term function for passing command line options as below.

(defun my/term (program)
  (set-buffer (make-term "terminal" program nil "-l"))
  (term-mode)
  (term-char-mode)
  (switch-to-buffer "*terminal*"))

(custom-set-variables
 '(shell-pop-term-shell "/usr/local/bin/bash")
 '(shell-pop-shell-type (quote ("terminal" "*terminal*"
                                (lambda () (my/term shell-pop-term-shell))))))
mankoff commented 9 years ago

Yes that seems to work. Thank you.