• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Rename folder GitHub

 
Ranch Hand
Posts: 1402
3
Netbeans IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,

I created a project in Eclipse with name digital_marine22 (I pushed it to Github) then I renamed it in local to digitalMarineHS.

Now I would like to rename it also in Github.

I don't find a way to do it. Any tips, please?

Image attached.

Regards,


git.PNG
[Thumbnail for git.PNG]
 
Saloon Keeper
Posts: 15510
363
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Just commit and push.
 
Saloon Keeper
Posts: 27763
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think actually Angus wants to rename the GitHub project name. I haven't used GitHub lately, since I have my own GitHub-like server (GOGS), but certainly GOGS does have an administrative function to do that.

It's worth noting that while the project name in git typically matches the pulled project directory name, it does not have to. There's a "git clone" option for using a different name locally. The project name on the server isn't literally a "directory name", it is, in fact, a project name.
 
Stephan van Hulst
Saloon Keeper
Posts: 15510
363
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In the image posted, digitalMarineGit is the repository name and digital_marine22 is a folder, so I'm assuming the OP really does want to just push their folder rename to GitHub.

In the event that the repository itself should be renamed, this can be done in the repository settings, I think there is a section called "Danger Zone" where you can do this.
 
Tim Holloway
Saloon Keeper
Posts: 27763
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Angus Ferguson wrote:Hi all,

I created a project in Eclipse with name digital_marine22 (I pushed it to Github) then I renamed it in local to digitalMarineHS.

Now I would like to rename it also in Github.



There is room for confusion there, but chances are high that the Eclipse project name/Eclipse project folder name (not neccesarily the same thing) was digital_marine22. And that it was then published to GitHub as digital_marine22.

Making the (possibly incorrect) assumption that the project name/project folder name was then changed in Eclipse to digitalMarineHS and that it was designed to rename GitHub project digital_marine22 to digitalMarineHS.

That would actually require two operations. One would be to use the GitHub "Danger Zone" to rename the project on GitHub. But if you left it there, then future push/pull requests from Eclipse project digitalMarineHS would still be trying to work with the now-undefined GitHub digitalMarineHS.

So in addition to renaming on GitHub, you would also have to alter the "git remote" URLs for the local copy of the project to reference GitHub digitalMarineHS.

At least on GOGs, where the Git repository name is part of the URL. And I'd expect that GitHub works the same, simply because it's simpler that way.
reply
    Bookmark Topic Watch Topic
  • New Topic