Jump to content


Case-Aware C1


  • Please log in to reply
4 replies to this topic

#1 Skylonxe

Skylonxe

    Member

  • Members
  • PipPip
  • 13 posts

Posted 14 April 2020 - 11:07 AM

When running windows server which is case-insensitive, uploading file from "File.txt" from Windows client leaves it as "File.txt".
Whe running unix server with C1, uploading "File.txt" from Windows client changes it to "file.txt".

Is it possible to somehow make unix server case insensitive but case aware?

#2 Sambwise

Sambwise

    Advanced Member

  • Members
  • PipPipPip
  • 1192 posts

Posted 14 April 2020 - 03:34 PM

View PostSkylonxe, on 14 April 2020 - 11:07 AM, said:

When running unix server with C1, uploading "File.txt" from Windows client changes it to "file.txt".

Are you positive that this is what's happening?  IIRC the case-insensitive Unix server will lowercase the archive file on the backend filesystem, but the "front end" (i.e. the db and all the end-user commands that go through it) should preserve the original case.

#3 Skylonxe

Skylonxe

    Member

  • Members
  • PipPip
  • 13 posts

Posted 15 April 2020 - 08:58 AM

View PostSambwise, on 14 April 2020 - 03:34 PM, said:

Are you positive that this is what's happening?  IIRC the case-insensitive Unix server will lowercase the archive file on the backend filesystem, but the "front end" (i.e. the db and all the end-user commands that go through it) should preserve the original case.


P4V was showing everything as lower case in Depot view while Workspace view had correct cases. After creating new workspace and getting latest revision, I received lowercase files too, weird. I could not get rid of that behavior, so I recreated server using same steps today to give you nice reproduction steps and now it works correctly even with C1. I can not explain it.



#4 Sambwise

Sambwise

    Advanced Member

  • Members
  • PipPipPip
  • 1192 posts

Posted 15 April 2020 - 02:24 PM

On a case-insensitive server, you can get a situation like what you describe by manually specifying a different case from what's on disk, e.g.:


C:\Perforce\test\case>echo asdf > Foo

C:\Perforce\test\case>p4 add foo
//stream/main/case/foo#1 - opened for add

C:\Perforce\test\case>dir
 Volume in drive C is OS
 Volume Serial Number is AE05-0B05

 Directory of C:\Perforce\test\case

04/15/2020  07:19 AM	<DIR>		  .
04/15/2020  07:19 AM	<DIR>		  ..
04/15/2020  07:19 AM				 7 Foo
			   1 File(s)			  7 bytes
			   2 Dir(s)  752,660,496,384 bytes free

C:\Perforce\test\case>p4 opened
//stream/main/case/foo#1 - add default change (text)

If I don't explicitly specify the case, it will instead match what's on my local disk:



C:\Perforce\test\case>p4 revert ...
//stream/main/case/foo#none - was add, abandoned

C:\Perforce\test\case>p4 add ...
//stream/main/case/Foo#1 - opened for add

C:\Perforce\test\case>p4 submit -d foo
Submitting change 152.
Locking 2 files ...
add //stream/main/case/Foo#1

Once I've submitted the file, it will keep that "Foo" case even if I refer to it as "foo" later (the case-insensitive server is still case-preserving).

#5 Skylonxe

Skylonxe

    Member

  • Members
  • PipPip
  • 13 posts

Posted 16 April 2020 - 10:52 AM

View PostSambwise, on 15 April 2020 - 02:24 PM, said:

On a case-insensitive server, you can get a situation like what you describe by manually specifying a different case from what's on disk, e.g.:


C:\Perforce\test\case>echo asdf > Foo

C:\Perforce\test\case>p4 add foo
//stream/main/case/foo#1 - opened for add

C:\Perforce\test\case>dir
Volume in drive C is OS
Volume Serial Number is AE05-0B05

Directory of C:\Perforce\test\case

04/15/2020 07:19 AM <DIR> .
04/15/2020 07:19 AM <DIR> ..
04/15/2020 07:19 AM 7 Foo
1 File(s) 7 bytes
2 Dir(s) 752,660,496,384 bytes free

C:\Perforce\test\case>p4 opened
//stream/main/case/foo#1 - add default change (text)

If I don't explicitly specify the case, it will instead match what's on my local disk:



C:\Perforce\test\case>p4 revert ...
//stream/main/case/foo#none - was add, abandoned

C:\Perforce\test\case>p4 add ...
//stream/main/case/Foo#1 - opened for add

C:\Perforce\test\case>p4 submit -d foo
Submitting change 152.
Locking 2 files ...
add //stream/main/case/Foo#1

Once I've submitted the file, it will keep that "Foo" case even if I refer to it as "foo" later (the case-insensitive server is still case-preserving).

I see, that clarifies it a bit! So the problem was not related to server at all. I added files only using P4V, so something like that could have been somehow done by the client. Thanks!




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users