12

I realize that changing the name of a Git repository is not a trivial task, and I read the answer to this question which describes how to change the repository name in the general case (I am also using GitHub).

However, I will only be changing the case of the repository name, e.g. Abc to abc. Therefore, can I simply change the name in the settings page of my repository on GitHub and be all set? Or do I still need to follow the steps outlined in the previous link?

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
arshajii
  • 127,459
  • 24
  • 238
  • 287
  • 6
    Yes - the repository names *are* case sensitive. "abc" != "Abc". *HOWEVER* DNS names (including the host name part of URLs) *are* case-insensitive (http://GOOGle.CoM == http://google.com). – paulsm4 Jan 08 '13 at 23:05
  • 1
    @paulsm4: github urls are not case sensitive – PinnyM Jan 08 '13 at 23:06
  • Yes they *can be*. Look [here](http://stackoverflow.com/questions/6650488/why-are-github-project-document-page-urls-case-sensitive-what-are-the-negative), [here](https://help.github.com/articles/error-repository-not-found) and [here](https://metacpan.org/module/App::GitHub::FindRepository). And remember: A "url" consists of multiple parts. – paulsm4 Jan 08 '13 at 23:10
  • +1 @paulsm4: I take it back - the behavior is not guaranteed and might just be case-sensitive. – PinnyM Jan 08 '13 at 23:20

1 Answers1

4

After experimenting a bit, I found that you cannot simply change the repository name in the settings page. The steps from the link in the body of the question must still be followed. Although in my case it was as simple as:

git remote set-url origin https://github.com/username/newreponame.git
Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
arshajii
  • 127,459
  • 24
  • 238
  • 287