From: Leo Liu <sdl.web@gmail.com>
To: 20873@debbugs.gnu.org
Subject: bug#20873: 24.5; shell command completion faulty
Date: Mon, 22 Jun 2015 21:24:50 +0800 [thread overview]
Message-ID: <m17fqvswnx.fsf@zeuss-MBP.lan> (raw)
1. M-x shell
2. Put a few spaces before entering `c' followed by TAB
No completion.
I wonder if the following is the right fix?
diff --git a/lisp/shell.el b/lisp/shell.el
index 6d69ca63..788b8169 100644
--- a/lisp/shell.el
+++ b/lisp/shell.el
@@ -1134,7 +1134,9 @@ (defun shell-command-completion ()
(if (and filename
(save-match-data (not (string-match "[~/]" filename)))
(eq (match-beginning 0)
- (save-excursion (shell-backward-command 1) (point))))
+ (save-excursion (shell-backward-command 1)
+ (skip-syntax-forward " ")
+ (point))))
(shell--command-completion-data))))
(defun shell--command-completion-data ()
next reply other threads:[~2015-06-22 13:24 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-06-22 13:24 Leo Liu [this message]
2015-06-22 22:13 ` bug#20873: 24.5; shell command completion faulty Stefan Monnier
2015-06-23 1:26 ` Leo Liu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m17fqvswnx.fsf@zeuss-MBP.lan \
--to=sdl.web@gmail.com \
--cc=20873@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.