How do you change a repository description on GitHub?
Asked Answered
M

10

290

When you create a repository on GitHub, you can optionally create a description of the repository. Unfortunately, I wrote a description that no longer adequately describes the code in the repo.

How do I change the repo description?

Macey answered 13/10, 2011 at 17:5 Comment(0)
A
129

Meta-information about the repository can be changed by clicking on a cog icon in the right-hand side menu's "About" section:

2020 design: edit cog

Upon doing so, a popup will appear where the description, website, topics, and homepage settings can be configured:

2020 design: edit popup

Abscission answered 13/10, 2011 at 17:5 Comment(7)
Watch out: you can only get to this if you have 1 or more files in your repo!Emie
@Emie - well, yeah, kind of stayed the same, the other answer here is still correct in that regards.Abscission
yep, that's why I upvoted that one :-) Above answer + screenshot is spot on - provided you have one or more files in your repo, which I only figured out when I read the answer below.Emie
@Emie - I think editing empty repo description and metadata is not that useful, but I agree that it would certainly be nice to have - after all, why should it depend on having files in a repo? Something tells me this is an oversight when changing the legacy UI (after all, the empty repo layout did not change much)Abscission
in my case, I was setting up some empty repos for other developers and tried to convey the purpose of each repo in the description. However, I made mistake (used the same description twice) and couldn't correct it, so that made it confusing for the devs. I then had to put a dummy file in there to correct my mistake, which did not provide the best user experience...Emie
@Emie - thank you for sharing your use case for empty repositories. Although I do think that even template repositories should contain at least a license file or a directory structure, admittedly, the inability to edit metadata if there is no data would not be my choice of user experience, I agree.Abscission
Why is it not possible to describe a repo on the cmd and push it to github, and they do kungfu and put it to the right place? I still do not like guis..Nephoscope
A
216

They changed the looks slightly, the "Edit" button is seen when on the repositories main page, which is the "Code" tab. Here is a screencast/animated-screenshot:

enter image description here

Arwood answered 8/2, 2014 at 17:8 Comment(7)
For a github newcomer like me, this was the most confusing accepted solution I've ever seen. According to me, 1) Hovering (where?) doesn't do anything related at all. 2) The addon on the screenshot is unrelated. I bet the screenshot intends to point out the "- Edit" suffix, which acts as a button. It's obvious enough that newcomers wouldn't go searching and land on this question, so the reason you did land here, is: 3) It's not always visible, as noted by Sergio in the comment above. It appears only after adding to the initially created repository (or something like that).Eastbound
Thanks @Eastbound if you can modify that screenshot and update that would be nice. Maybe blur out the text, and draw an arrow at the "Edit"Arwood
Sure @Noitidart, that new image is a splendid way to eliminate one source of confusion.Eastbound
If you don't see it, make sure the account you are logged in with can contribute to that repo.Ides
Which tools did you use to create that video before uploading to imgur?Twana
@Twana I used Camtasia StudioArwood
The appearance has changed again. Look for a settings gear at top right, as mentioned in other answers.Trinia
A
129

Meta-information about the repository can be changed by clicking on a cog icon in the right-hand side menu's "About" section:

2020 design: edit cog

Upon doing so, a popup will appear where the description, website, topics, and homepage settings can be configured:

2020 design: edit popup

Abscission answered 13/10, 2011 at 17:5 Comment(7)
Watch out: you can only get to this if you have 1 or more files in your repo!Emie
@Emie - well, yeah, kind of stayed the same, the other answer here is still correct in that regards.Abscission
yep, that's why I upvoted that one :-) Above answer + screenshot is spot on - provided you have one or more files in your repo, which I only figured out when I read the answer below.Emie
@Emie - I think editing empty repo description and metadata is not that useful, but I agree that it would certainly be nice to have - after all, why should it depend on having files in a repo? Something tells me this is an oversight when changing the legacy UI (after all, the empty repo layout did not change much)Abscission
in my case, I was setting up some empty repos for other developers and tried to convey the purpose of each repo in the description. However, I made mistake (used the same description twice) and couldn't correct it, so that made it confusing for the devs. I then had to put a dummy file in there to correct my mistake, which did not provide the best user experience...Emie
@Emie - thank you for sharing your use case for empty repositories. Although I do think that even template repositories should contain at least a license file or a directory structure, admittedly, the inability to edit metadata if there is no data would not be my choice of user experience, I agree.Abscission
Why is it not possible to describe a repo on the cmd and push it to github, and they do kungfu and put it to the right place? I still do not like guis..Nephoscope
A
106

Click on the Edit that comes when you hover your mouse over the description and project url section

enter image description here

Ayotte answered 13/10, 2011 at 17:12 Comment(3)
They need to change this. The fact I had to turn to Stack Overflow for the answer is shocking. ThanksApproach
apparently the description only appears in the details of the project if the project is not empty !. I had to commit something before being able to change it.Spencerspencerian
Ya that was the most confusing part, I was creating a bunch of empty repos for moving a few projects over ><Geophyte
A
56

When you hover over the existing description, an Edit button will appear at the far left.

enter image description here

Austria answered 13/10, 2011 at 17:12 Comment(0)
F
50

Just in case anyone else has a similar issue as me...

You cannot edit the description until one or more files are committed and pushed. In my specific case, I created the repository from IntelliJ IDEA and accidentally filled the description with text I had intended for the first commit. However, I didn't actually commit or push any files.

I went to the repositories page on the GitHub website, where I could see the repository and its description from the repositories page. However, when viewing the individual repository page, the description would not appear and suggestions for setting up the project were the only content displayed. There is no clear indication that you cannot edit the description until a file is uploaded, but once you have done so, the description is clearly displayed and with it a link to edit.

Fic answered 25/6, 2016 at 20:15 Comment(2)
This is a completely messed up user experience. There is absolutely no reason why the repository description would not just be on the repository Settings page.Effluent
/\ I can't stress that enough.Carson
P
17

enter image description here

Click on the gear icon like in the image, and then change your repository description

enter image description here

Click "Save Changes"

Paper answered 24/2, 2022 at 5:45 Comment(3)
Can you please include a description of the steps outlined by your images? It may not be understandable for everyone (for example, think of screenreaders)Visigoth
Please note that this gear icon is NOT visible if the repository is empty / has no commits.Nixie
This same answer has already given, multiple times before this. As well, this answer is completely useless to anyone who can't see the images.Tollgate
E
11

1.Go into your repository.

2.On the right side About and symbol of setting.

About and Setting

3.Click on the setting.

4.You get Edit repository details.

5.you can change details.

Edit Description

Expositor answered 21/11, 2020 at 11:13 Comment(3)
apparently this is only applicable for public repo. cant we do the same to private repo?Sleep
@HadiKAR it works on my own private repos. It's only for empty repos that I cannot do it.Paperback
This answer was already present for months before this one, and says exactly the same thing.Tollgate
D
7

You can do so directly from command-line, without having to interact with GitHub website.

Since the GitHub CLI gh 2.4.0, you can use gh repo edit:

gh repo edit --description="your_description"

# Update the description of the repository
Dire answered 22/12, 2021 at 22:47 Comment(0)
F
5

As of 2023, Github UI has been updated again and the option is now located in the top-right corner of a repository page. Click on the Gear Icon next to About, and a new modal will pop up where you can change the description of the repository.

enter image description here

Forebrain answered 23/1, 2023 at 17:47 Comment(1)
This is no different from this already existing answer.Tollgate
F
2

from this Gear Button

press the Gear Button and you will see the description to update it or delete it

Fane answered 4/10, 2022 at 23:37 Comment(1)
This solution was already given here and this answer is useless to anyone unable to see the image.Tollgate

© 2022 - 2024 — McMap. All rights reserved.