1. About Labels
In an earlier document, How to Create GitLab Labels Automatically with python-gitlab, I already explained that Labels can be used for simple project management.
A team usually has more than one code repository. To reduce the cost of communication and learning, besides using a consistent toolchain, it should also reach a certain basic consensus. This basic consensus pushes everyone toward the best practices. One such item is that under the same large project, all sub-projects use the same set of Labels.
2. How to Copy Labels from Other Projects
In the open source community, there are projects with considerable influence in their field. Participating in and following the community’s practices is a good choice. We can create a Token on the settings/tokens page to sync labels from other projects. There is no permission requirement for this Token, so no option needs to be checked.
- Install PyGithub
| |
- Run the script below, replacing the relevant variables
| |
