emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master 4ee82a4 3/4: Merge from origin/emacs-26


From: Glenn Morris
Subject: [Emacs-diffs] master 4ee82a4 3/4: Merge from origin/emacs-26
Date: Mon, 4 Jun 2018 12:29:14 -0400 (EDT)

branch: master
commit 4ee82a4ea98a17362fe36bfd5253eda768003683
Merge: a3ec2e7 03697e6
Author: Glenn Morris <address@hidden>
Commit: Glenn Morris <address@hidden>

    Merge from origin/emacs-26
    
    03697e6 Fix remote-host directory tracking for shells in `term' buffers
    16e8541 Update doc string of 'rx'
---
 lisp/emacs-lisp/rx.el | 18 ++++++++++++------
 lisp/term.el          | 31 ++++++++++++++++---------------
 2 files changed, 28 insertions(+), 21 deletions(-)

diff --git a/lisp/emacs-lisp/rx.el b/lisp/emacs-lisp/rx.el
index 358f9db..85e74f2 100644
--- a/lisp/emacs-lisp/rx.el
+++ b/lisp/emacs-lisp/rx.el
@@ -978,12 +978,14 @@ CHAR
      matches whitespace and graphic characters.
 
 `alphanumeric', `alnum'
-     matches alphabetic characters and digits.  (For multibyte characters,
-     it matches according to Unicode character properties.)
+     matches alphabetic characters and digits.  For multibyte characters,
+     it matches characters whose Unicode `general-category' property
+     indicates they are alphabetic or decimal number characters.
 
 `letter', `alphabetic', `alpha'
-     matches alphabetic characters.  (For multibyte characters,
-     it matches according to Unicode character properties.)
+     matches alphabetic characters.  For multibyte characters,
+     it matches characters whose Unicode `general-category' property
+     indicates they are alphabetic characters.
 
 `ascii'
      matches ASCII (unibyte) characters.
@@ -992,10 +994,14 @@ CHAR
      matches non-ASCII (multibyte) characters.
 
 `lower', `lower-case'
-     matches anything lower-case.
+     matches anything lower-case, as determined by the current case
+     table.  If `case-fold-search' is non-nil, this also matches any
+     upper-case letter.
 
 `upper', `upper-case'
-     matches anything upper-case.
+     matches anything upper-case, as determined by the current case
+     table.  If `case-fold-search' is non-nil, this also matches any
+     lower-case letter.
 
 `punctuation', `punct'
      matches punctuation.  (But at present, for multibyte characters,
diff --git a/lisp/term.el b/lisp/term.el
index 715f39b..9aa4a20 100644
--- a/lisp/term.el
+++ b/lisp/term.el
@@ -229,31 +229,33 @@
 ;;
 ;;  Notice: for directory/host/user tracking you need to have something
 ;; like this in your shell startup script (this is for a POSIXish shell
-;; like Bash but should be quite easy to port to other shells)
+;; like Bash but should be quite easy to port to other shells).
+;;
+;; For troubleshooting in Bash, you can check the definition of the
+;; custom functions with the "type" command.  e.g. "type cd".  If you
+;; do not see the expected definition from the config below, then the
+;; directory tracking will not work.
 ;;
 ;;             ----------------------------------------
 ;;
-;;  # Set HOSTNAME if not already set.
+;;     # Set HOSTNAME if not already set.
 ;;     : ${HOSTNAME=$(uname -n)}
 ;;
-;;  # su does not change this but I'd like it to
-;;
+;;     # su does not change this but I'd like it to
 ;;     USER=$(whoami)
 ;;
-;;  # ...
+;;     # ...
 ;;
 ;;     case $TERM in
 ;;         eterm*)
 ;;
 ;;             printf '%s\n' \
 ;;              -------------------------------------------------------------- 
\
-;;              "Hello $user" \
+;;              "Hello $USER" \
 ;;              "Today is $(date)" \
 ;;              "We are on $HOSTNAME running $(uname) under Emacs term mode" \
 ;;              --------------------------------------------------------------
 ;;
-;;             export EDITOR=emacsclient
-;;
 ;;             # The \033 stands for ESC.
 ;;             # There is a space between "AnSiT?" and $whatever.
 ;;
@@ -265,10 +267,11 @@
 ;;             printf '\033AnSiTh %s\n' "$HOSTNAME"
 ;;             printf '\033AnSiTu %s\n' "$USER"
 ;;
-;;             eval $(dircolors $HOME/.emacs_dircolors)
+;;             # Use custom dircolors in term buffers.
+;;             # eval $(dircolors $HOME/.emacs_dircolors)
 ;;     esac
 ;;
-;;  # ...
+;;     # ...
 ;;
 ;;
 
@@ -2742,12 +2745,10 @@ See `term-prompt-regexp'."
        (setq default-directory
              (file-name-as-directory
               (if (and (string= term-ansi-at-host (system-name))
-                                       (string= term-ansi-at-user 
(user-real-login-name)))
+                        (string= term-ansi-at-user (user-real-login-name)))
                   (expand-file-name term-ansi-at-dir)
-                (if (string= term-ansi-at-user (user-real-login-name))
-                    (concat "/" term-ansi-at-host ":" term-ansi-at-dir)
-                  (concat "/" term-ansi-at-user "@" term-ansi-at-host ":"
-                          term-ansi-at-dir)))))
+                 (concat "/-:" term-ansi-at-user "@" term-ansi-at-host ":"
+                         term-ansi-at-dir))))
 
        ;; I'm not sure this is necessary,
        ;; but it's best to be on the safe side.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]