[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Case sensitivity bug in windows with powershell.

From: Johan Corveleyn <jcorvel_at_gmail.com>
Date: Mon, 12 Nov 2012 13:13:12 +0100

On Mon, Nov 12, 2012 at 11:54 AM, Sebastian Andersson <bofh69_at_gmail.com> wrote:
> On Mon, Nov 12, 2012 at 11:44 AM, Johan Corveleyn <jcorvel_at_gmail.com> wrote:
>> For those that are not too familiar with powershell (like me): what
>> does Set-LocationEx do?
>>
>> Does it do a rename of APA to apa (like the more usual Windows command
>> 'move APA apa' does)?
>
> Sorry about that, I should have been more clear. No, it is "cd" in
> almost every other shell (and usually in powershell too via aliases).

Hm, I don't see this problem with "cd" in cmd.exe. The cd command does
automatically use on the correct casing of the directory:

[[[
C:\Temp\svntest>svn --version -q
1.7.7-SlikSvn-1.7.7-X64

C:\Temp\svntest>svnadmin create repos

C:\Temp\svntest>svn co file:///C:/Temp/svntest/repos wc
Checked out revision 0.

C:\Temp\svntest>cd wc

C:\Temp\svntest\wc>svn mkdir APA
A APA

C:\Temp\svntest\wc>cd apa

C:\Temp\svntest\wc\APA>svn mkdir banan
A banan
]]]

You see that the last prompt correctly shows APA, the exact casing
like it is on disk, even though I asked Windows to cd into apa. That
looks like the correct behavior of Windows (case-insensitive, but
case-preserving (so showing/using the known casing wherever it is
used)).

So IMO the problem is with the Set-LocationEx call that you do (or the
Windows implementation thereof). It seems to me that Windows should be
consistent and cd you into the correctly cased directory (whichever
case you ask for). Alternatively, maybe Set-LocationEx is documented
as showing this rather strange behavior (in that case, you should not
use it, or you should make sure yourself that the case you ask for is
correct before you call Set-LocationEx).

-- 
Johan
Received on 2012-11-12 13:14:10 CET

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.