OpenMined / .github

All our community health files
Apache License 2.0
7 stars 13 forks source link

AUTOMATION - Add organization repo labels to all repos individually #13

Closed cereallarceny closed 4 years ago

cereallarceny commented 4 years ago

Description

I added a ton of repo labels to the Github organization, but apparently they only add to new repos. So damn depressing. Can we write a script that would automatically copy these labels I worked to hard on to all of our 50-ish existing repositories so I don't have to do this manually?

Organization level repo labels: https://github.com/organizations/OpenMined/settings/labels Description of the problem: https://help.github.com/en/github/setting-up-and-managing-organizations-and-teams/managing-default-labels-for-repositories-in-your-organization

Are you interested in working on this improvement yourself?

Additional Context

None

Nilanshrajput commented 4 years ago

Organization level repo labels: https://github.com/organizations/OpenMined/settings/labels

@cereallarceny this link is giving 404 error, is it due to some permissions?

cereallarceny commented 4 years ago

Yes. Only myself, Trask, or Ben can do this issue.

Nilanshrajput commented 4 years ago

Hi @cereallarceny I created a script for adding labels across the all OpenMined repos, https://gist.github.com/Nilanshrajput/202c9fc6b8e251ea4699e7e6b9b2144a

You might need to do little updates for auth etc, let me know if you face any issue

tcp commented 4 years ago

Hey @Nilanshrajput! Thank you :)

Unfortunately, I can't use your script to replace all the labels -- we don't want to delete existing labels for the projects, just rename where appropriate.

I'm doing this and I will complete this afternoon.

It's unfortunate -- but thank you very much for your work!

Nilanshrajput commented 4 years ago

@tcp you can just comment out delete label function, it will just add the labels to existing set of labels, and will overwrite if same name!

tcp commented 4 years ago

That's the thing -- we have to manually pass through every repo and make a judgment call if an existing label fits any of the new labels.

What I'm doing is adding all the labels through the script to all repo's and going through each of them renaming where appropriate :)

tcp commented 4 years ago

@cereallarceny hey bud, I saw some of the old labels in some repo's, like Duplicate, Invalid, Help Wanted and Wont fix and they don't have a matching new label. Do you want to incorporate them?

tcp commented 4 years ago

@cereallarceny I've just finished modifying labels for all OpenMined repos (minus PySyft). I ran a script to update the labels where it was required and create the ones that were missing.

Labels that remained unchanged and are set by default or interesting:

cereallarceny commented 4 years ago

Done by @tcp