keith-b-git / ct

Club Triumph
GNU General Public License v3.0
1 stars 0 forks source link

[Dev] Case-insensitive OS/Volume compatibility. #21

Closed meredevelopment closed 5 years ago

meredevelopment commented 5 years ago

The Bug

I have a problem with OS case-sensitivity, and anyone else developing this repo with Mac OS or Windows might have the same unless their volumes are set to case-sensitive. Git allows case-sensitive file 'duplicates'. e.g.

lib/ClubTriumph/Schedule/Messdiary.pm
lib/ClubTriumph/Schedule/messdiary.pm

To prove this try git ls-tree HEAD lib/ClubTriumph/Schedule/ to see what Git has (of course on a Linux system one can see both in a normal file listing, but for me on Mac OS I only see 'messdiary.pm'.

Here's the complete list:

lib/ClubTriumph/Form/EventMan.pm
lib/ClubTriumph/Form/HTMLcontent.pm
lib/ClubTriumph/Schedule/Messdiary.pm
lib/ClubTriumph/Schema/Result/ChampPoint.pm
root/static/images/Forum.png

Fix

For each of those files, decide if they are duplicates and if so, delete unused one. If they are both needed, please rename one - updating any references to it - and stage/commit the changes.

Steps to Reproduce the Problem

  1. Checkout the repo on a Case-insensitive volume.
  2. Observe that Git immediately report local modifications.

Notes

For a rainy day, if this needed to be done from the Case-insensitive end, it would probably be a case of (assuming just both files are duplicates) :

  1. mv messdiary.pm messdiary.pm.keep
  2. git add . assuming this is the only change, careful.
  3. mv messdiary.pm.keep Messdiary.pm
  4. git status should show messdiary.pm as deleted and Messdiary.pm as modified.
  5. Commit and hope.
keith-b-git commented 5 years ago

Should be all gone now.