fu: Close-up of Fu, bringing a scoop of water to her mouth (Default)
fu ([personal profile] fu) wrote in [site community profile] dw_dev2012-12-30 02:59 am
Entry tags:

Case conflict: Sinisteria.jpeg

I had some weird behavior on my computer (running Mac OSX), because we had an image file named Sinisteria.jpeg, and another named sinisteria.jpeg, so I committed a fix.

Depending on your OS, you may need to run an extra step next time you upgrade. You'll need this for Mac OSX for sure, I can't remember how Windows and Linux deal with case in filenames.

Pull in updates as usual. This will delete Sinisteria.jpeg (uppercase)

$ git pull

Updating ecc1d71..7cb6ab7
Fast-forward
htdocs/img/styles/paperme/Sinisteria.jpeg | Bin 786 -> 0 bytes
1 file changed, 0 insertions(+), 0 deletions(-)
delete mode 100644 htdocs/img/styles/paperme/Sinisteria.jpeg


Then check if you accidentally deleted sinisteria.jpeg (lowercase)

$ git status
# On branch develop
# Changes not staged for commit:
# (use "git add/rm ..." to update what will be committed)
# (use "git checkout -- ..." to discard changes in working directory)
#
# deleted: htdocs/img/styles/paperme/sinisteria.jpeg
#


If you didn't see the "deleted: ..." bit, you're fine. No need to do anything more.

If you do see the "deleted:..." bit, then do this:
git checkout -- htdocs/img/styles/paperme/sinisteria.jpeg

Now check again to make sure that worked:
$ git status
# On branch develop
nothing to commit (working directory clean)


Done!
cdybedahl: (Default)

[personal profile] cdybedahl 2012-12-29 10:51 pm (UTC)(link)
Both OSX and Windows are by default case-insensitive but case-preserving, so they'll both have a problem with these files.

[personal profile] swaldman 2012-12-29 11:47 pm (UTC)(link)
Linux is case-sensitive, so presumably those of us on 'hacks don't need to worry?
momijizukamori: Grey tabby cat with paws on keyboard and mouse. The text reads 'code cat is on the job', lolcats-style (CODE CAT)

[personal profile] momijizukamori 2012-12-30 07:25 am (UTC)(link)
And you have also successfully guessed how this bug got in >_>

(I am preeeeeeetty sure it's my fault, because I patched all those themes initially)
ninetydegrees: Art & Text: heart with aroace colors, "you are loved" (Default)

[personal profile] ninetydegrees 2012-12-30 01:20 am (UTC)(link)
I upgraded before I saw this but the lowercase file is still there on my hack (windows) and loads fine so does that mean everything's ok?
pne: A picture of a plush toy, halfway between a duck and a platypus, with a green body and a yellow bill and feet. (Default)

[personal profile] pne 2013-01-03 01:34 pm (UTC)(link)
LiveJournal's code repository has (or had for quite a while) files which differed only in case; this caused problems checking out the code tree on Windows since the client (may even still have been CVS back in the day) complained that a file with that name already existed while trying to check out the second file.
kareila: woman with red hair and glasses looking into a computer screen (oracle)

[personal profile] kareila 2013-01-07 03:56 pm (UTC)(link)
I ran into that problem too. I worked around it by creating a disk image that used a case sensitive filesystem, and checking out the code onto that volume.