From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: MIYASHITA Hisashi(=?ISO-2022-JP?B?GyRCNVwyPBsoQiAbJEI+MBsoQjpISU1J?=) Newsgroups: gmane.emacs.devel Subject: Re: init_buffer PWD fix Date: Thu, 25 Apr 2002 04:41:15 +0900 Sender: emacs-devel-admin@gnu.org Message-ID: References: <8296-Wed24Apr2002190326+0300-eliz@is.elta.co.il> <200204241919.g3OJJ3104590@shade.twinsun.com> NNTP-Posting-Host: localhost.gmane.org Mime-Version: 1.0 (generated by SEMI 1.14.3 - "Ushinoya") Content-Type: text/plain; charset=US-ASCII X-Trace: main.gmane.org 1019677364 31651 127.0.0.1 (24 Apr 2002 19:42:44 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 24 Apr 2002 19:42:44 +0000 (UTC) Cc: emacs-devel@gnu.org, knagano@sodan.org Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by main.gmane.org with esmtp (Exim 3.33 #1 (Debian)) id 170Sf6-0008EO-00 for ; Wed, 24 Apr 2002 21:42:44 +0200 Original-Received: from fencepost.gnu.org ([199.232.76.164]) by quimby.gnus.org with esmtp (Exim 3.12 #1 (Debian)) id 170Sgu-0003Mf-00 for ; Wed, 24 Apr 2002 21:44:36 +0200 Original-Received: from localhost ([127.0.0.1] helo=fencepost.gnu.org) by fencepost.gnu.org with esmtp (Exim 3.34 #1 (Debian)) id 170Sek-0000Yi-00; Wed, 24 Apr 2002 15:42:22 -0400 Original-Received: from meadow.scphys.kyoto-u.ac.jp ([130.54.54.165]) by fencepost.gnu.org with smtp (Exim 3.34 #1 (Debian)) id 170Sdh-0000VT-00 for ; Wed, 24 Apr 2002 15:41:18 -0400 Original-Received: (qmail 7094 invoked from network); 24 Apr 2002 19:40:32 -0000 Original-Received: from meadow.meadow.scphys.kyoto-u.ac.jp (HELO MILCH.meadowy.org.meadowy.org) (root@172.16.1.1) by meadow.meadow.scphys.kyoto-u.ac.jp with SMTP; 24 Apr 2002 19:40:32 -0000 Original-To: Paul Eggert In-Reply-To: <200204241919.g3OJJ3104590@shade.twinsun.com> (Paul Eggert's message of "Wed, 24 Apr 2002 12:19:03 -0700 (PDT)") Original-Lines: 47 User-Agent: T-gnus/6.15.4 (based on Oort Gnus v0.04) (revision 11) SEMI/1.14.3 (Ushinoya) FLIM/1.14.2 (Yagi-Nishiguchi) APEL/10.3 Emacs/21.1 (i386-msvc-nt5.1.2600) MULE/5.0 (SAKAKI) Meadow/1.99 Alpha1 (AWOFUCHI) Errors-To: emacs-devel-admin@gnu.org X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.0.9 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.devel:3213 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:3213 Paul Eggert writes: > This should happen only if either: > > A) the user types "cd c:/PROGRA~1"; or > B) getcwd returns "c:/PROGRA~1" when sh starts up. > > In case A), the user has indicated a preference for the name "c:/PROGRA~1", > so that is a better name for Emacs to use. > > In case B), there's no difference between using PWD and using getcwd, > so there's no problem. Why are they no problem? In the example I offered, after doing it, user type "cd c:/Program Files" during cmd.exe session. But Emacs set the default directory to "c:/PROGRA~1". It must be a problem. I can imagin lots of similar cases in plausible user operations. For example, a user may like to invoke explorer.exe to browse a directory and then invoke emacs.exe by the invoked explorer.exe. If the user uses a normal pathname on tcsh.exe but uses UNC pathname to specify the current directory for emacs.exe on explorer.exe, and those locations are the same. The user will encounter a problem. >> The above case is an example to affirm relying on "PWD" by obscure >> convension is maybe harmful. > > It's not an obscure convention; it's in the POSIX standard. Also I've already said that in the previous mail. >> But "PWD" is NOT cared by almost all of the Windows application. >> On the contrary, Get/SetCurrentDirectory() is always cared. > > This is like Unix. On Unix, most applications don't use $PWD; they > use the working directory. The only applications that set and use > $PWD are those that care about using a "nice" name for the working > directory. I disagree on it. According to my knowledge, lots of Unix applications use "PWD". Almost all of shells set "PWD" properly. But on Windows, even the standard shell program, "cmd.exe" dose not set "PWD". With regards, from himi