From: PHO Date: Fri, 27 Mar 2015 08:40:01 +0000 (+0900) Subject: Auto commit by The Sugar System. X-Git-Url: https://git.cielonegro.org/gitweb.cgi?a=commitdiff_plain;h=fcd004a4fb12f378fc35a857695347429ec1dfab;p=sugar.git Auto commit by The Sugar System. --- diff --git a/dot-files/_emacs_el b/dot-files/_emacs_el index e8508e6..c05e740 100644 --- a/dot-files/_emacs_el +++ b/dot-files/_emacs_el @@ -141,6 +141,11 @@ (color-theme-initialize) (color-theme-subtle-hacker))) +;; multi-term +(autoload 'multi-term "multi-term" + "Create new term buffer. +Will prompt you shell name when you type `C-u' before this command." t) + ;; auto-complete (require-if-present 'auto-complete-config) (if (featurep 'auto-complete-config) diff --git a/dot-files/_zshrc b/dot-files/_zshrc index d800cc4..45ac9af 100644 --- a/dot-files/_zshrc +++ b/dot-files/_zshrc @@ -60,6 +60,10 @@ function _we_are_in_ssh_session () { [[ -n "$SSH_CONNECTION" ]] } +function _we_are_in_emacs () { + [[ -n "$INSIDE_EMACS" ]] +} + _prompt_base='%B[%n@%m] %{%(?.$fg[green].$fg[red])%}%#%{$reset_color%}%b ' if ( _we_are_in_gnu_screen ); then # GNU Screen has a capability to set its window title by "ESC k @@ -280,16 +284,17 @@ autoload -U compinit compinit # End of lines added by compinstall -if ( _we_are_in_gnu_screen ); then +if _we_are_in_gnu_screen; then # When we are in a GNU Screen session... - if ( _we_are_in_ssh_session ); then + if _we_are_in_ssh_session; then # Propagate remote session's bells to the local one. screen -X vbell off fi else - if [ -e ".motd" ]; then - cat ".motd" + if _we_are_in_emacs; then + # Without this, Emacs' term mode has trouble with backspaces. + export TERM=vt100 fi # Run "fortune" if we aren't in a GNU Screen session.