Click here to Skip to main content
Click here to Skip to main content
Technical Blog

Tagged as

Git, git extensions and the case-sensitive thing...

, 19 Nov 2011 CPOL
Rate this:
Please Sign up or sign in to vote.
Git, git extensions and the case-sensitive thing...

As a general rule, I always use some kind of source control on all my projects. As a matter of fact, I use GIT even when some people might find that weird, being myself a .NET developer .... But hey... GIT is in my opinion, one of the best things out there when it comes to really good team development tools.

Then the second part is to use it with people online, for that github.com is pretty good, and the final part is a good add-in for Visual Studio or a shell extension. I use Git-Extensions for all that and so far, except for the little problem I am going to explain here, I have no complains at all.

The Problem

Git branches are case-sensitive, so you can have "test" and "TEST" as different branches, and it will work fine if you use linux as a client. But when using git-extensions from Windows, I ran into a huge problem, where one of my friends was pushing code and I was not able to see it. She was uploading code to the same branch but just with different casing. It's just a typing mistake, and then you get what seems like a huge problem in your hands. The Git-Extensions tool will even show you the branches completely on UPPERCASE, so you won't have a chance at all, and picking any of them won't make any difference.

But it is not so difficult to fix it...

The Solution

Well, not pretty clean, but you can just delete the branch from github.com, and mix branches in local git. How to delete the branch from git-hub?, easy after some Googling:

git push MY_REMOTE :mybranch

and it worked fine! Note that right after MY_REMOTE there is a space. That means something like, take "nothing" from here and put it on the "mybranch" branch at "MY_REMOTE". Which is actually just deleting the branch. I would really love if they just add a command to just do that, or just add that option from the website itself.

Note: Careful with casing when using git on Windows!

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Leonardo Paneque
Team Leader
United States United States
Leonardo loves to code with C# and thinks .NET platforms rocks.
He has a Master degree in Computer Sciences and likes to share code and ideas.
Follow on   Twitter

Comments and Discussions

 
-- There are no messages in this forum --
| Advertise | Privacy | Terms of Use | Mobile
Web04 | 2.8.141216.1 | Last Updated 19 Nov 2011
Article Copyright 2011 by Leonardo Paneque
Everything else Copyright © CodeProject, 1999-2014
Layout: fixed | fluid