https://github.com/bukinoshita/git-labels
Creating Github issue labels
https://github.com/bukinoshita/git-labels
git github issues labels repo repository
Last synced: 24 days ago
JSON representation
Creating Github issue labels
- Host: GitHub
- URL: https://github.com/bukinoshita/git-labels
- Owner: bukinoshita
- License: mit
- Created: 2017-08-23T20:07:04.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2022-12-03T00:28:45.000Z (almost 3 years ago)
- Last Synced: 2025-09-15T07:22:00.884Z (about 2 months ago)
- Topics: git, github, issues, labels, repo, repository
- Language: JavaScript
- Homepage:
- Size: 548 KB
- Stars: 5
- Watchers: 1
- Forks: 1
- Open Issues: 12
-
Metadata Files:
- Readme: readme.md
- License: license
Awesome Lists containing this project
README
# git-labels [](https://travis-ci.org/bukinoshita/git-labels)
> Creating Github issue labels
## Install
```bash
$ yarn add git-labels
```
## Usage
```js
const gitLabels = require('git-labels')
const project = 'bukinoshita/git-labels'
const labels = [{ name: 'bug', color: 'cb2431' }]
const token = $token
await gitLabels({ project, labels, token })
// => Done!
```
## Why
I've been using Github issues labels a lot these days, but I never liked the default ones. So every project I have to **manually** `delete/create/update` my issues labels with the colors and names I want. This can be done with a single command using this module.
Before
After
labels names and colors are customizable.
## API
### gitLabels({ project, labels, token })
#### project
Type: `string`
Format: `org/repo`
Required
Github project.
#### labels
Type: `array`
Format: `[ { name: NAME, color: COLOR }, ... ]`
Default: [`labels.json`](https://github.com/bukinoshita/git-labels/tree/master/utils/labels.json)
Labels to be created
#### token
Type: `string`
Required
[Github access token](https://help.github.com/articles/creating-a-personal-access-token-for-the-command-line/)
## Related
- [git-labels-cli](https://github.com/bukinoshita/git-labels-cli) — CLI for this module
## License
MIT © [Bu Kinoshita](https://bukinoshita.io)