From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Chong Yidong Newsgroups: gmane.emacs.devel Subject: Re: [david.hansen@gmx.net: Re: comint's directory tracking doesn't understand \( or \)] Date: Sun, 04 Mar 2007 10:45:53 -0500 Message-ID: <87wt1xhv0u.fsf@stupidchicken.com> References: <871wk56tjh.fsf@localhorst.mine.nu> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1173023187 9072 80.91.229.12 (4 Mar 2007 15:46:27 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 4 Mar 2007 15:46:27 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Mar 04 16:46:21 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1HNsui-0002Ur-I5 for ged-emacs-devel@m.gmane.org; Sun, 04 Mar 2007 16:46:20 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HNsui-0008D2-4D for ged-emacs-devel@m.gmane.org; Sun, 04 Mar 2007 10:46:20 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HNsuW-0008CY-Ap for emacs-devel@gnu.org; Sun, 04 Mar 2007 10:46:08 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HNsuV-0008CH-UZ for emacs-devel@gnu.org; Sun, 04 Mar 2007 10:46:08 -0500 Original-Received: from south-station-annex.mit.edu ([18.72.1.2]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA:32) (Exim 4.52) id 1HNsuV-0007w9-J6 for emacs-devel@gnu.org; Sun, 04 Mar 2007 10:46:07 -0500 Original-Received: from grand-central-station.mit.edu (GRAND-CENTRAL-STATION.MIT.EDU [18.7.21.82]) by south-station-annex.mit.edu (8.13.6/8.9.2) with ESMTP id l24Fk4rj001869 for ; Sun, 4 Mar 2007 10:46:04 -0500 (EST) Original-Received: from outgoing-legacy.mit.edu (OUTGOING-LEGACY.MIT.EDU [18.7.22.104]) by grand-central-station.mit.edu (8.13.6/8.9.2) with ESMTP id l24Fjs00011487 for ; Sun, 4 Mar 2007 10:45:57 -0500 (EST) Original-Received: from localhost (SYDNEYPACIFIC-FIFTY-SIX.MIT.EDU [18.95.5.56]) ) by outgoing-legacy.mit.edu (8.13.6/8.12.4) with ESMTP id l24Fjr2Z013260 for ; Sun, 4 Mar 2007 10:45:54 -0500 (EST) Original-Received: from cyd by localhost with local (Exim 3.36 #1 (Debian)) id 1HNsuH-0000r2-00 for ; Sun, 04 Mar 2007 10:45:53 -0500 In-Reply-To: <871wk56tjh.fsf@localhorst.mine.nu> (David Hansen's message of "Sun\, 04 Mar 2007 14\:13\:22 +0100") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.95 (gnu/linux) X-Scanned-By: MIMEDefang 2.42 X-Spam-Score: -2.599 X-detected-kernel: Solaris 9.1 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:67294 Archived-At: David Hansen writes: > On Fri, 02 Mar 2007 12:44:48 -0500 Richard Stallman wrote: > >> Would someone please study this, install it if it is safe, then ack? > > Alone it's doing not that much. The attached patch should fix all > problems with shell-modes directory tracking and special characters > in directory names. > > I'm sorry that it's a bit longish, but the original regexps are a > bit to much for my small brain ;) I'm leery of introducing this kind of change into comint.el at this stage in the release. It doesn't seem to fit Richard's criterion of being "simple and safe". BTW, I can't seem to reproduce the problem referenced in the original bug report. M-x shell RET ~ $ cd /tmp/ /tmp $ mkdir /tmp/'(2007)' /tmp $ cd \(2007\) /tmp/(2007) $ pwd => /tmp/(2007) This is GNU Emacs 22.0.95.3 (i686-pc-linux-gnu, GTK+ Version 2.10.6) of 2007-03-04. Could this be a shell bug on certain systems? > The *shell* buffer attempts to cd into the current working directory > of the inferior shell process, but when that directory contains a ( or > ), it seems to get lost, for example: > > M-x shell RET > $ cd /tmp/ > $ mkdir /tmp/'(2007)' > $ cd \(2007\)/ > > The *shell* buffer ends up in /tmp/, not in /tmp/(2007)/ as expected. > > Note that if I use: > > $ cd '(2007)' > > instead, then the tracking works.