Skip to content

GLAC - GitHub labels as code

Actions
Store your labels as code in the repository
1.0.0
Latest
Star (0)

GitHub labels as code Action

Store your issue labels as code in your repository.

Inputs

Name Description Default
token Token to use to authorize label changes. (See Github Tokens) ${{ github.token }}
file Path to the file you store your labels in. ./.github/labels.json

Example usage

uses: jop-software/github-labels-as-code-action@v1.0
with:
  token: "${{ github.token }}"
  file: "./.github/labels.json"

Note: You need to execute this action after actions/checkout

If you want to see a real example of this action, take a look at the workflows from this repository 😉

Github Tokens

On Feb. 2, 2023 GitHub announced in a blog post that new generated GHA Tokens in repository will be read only by defaut.
Therefore, when you add the action to a repository created after 2023-02-02 you need to make sure to provide a GitHub token that has write access to update issue labels. This can be toggled in the repository settings.
When you are using inheritence for repository permissions, please read the GitHub Blog Post explaining that change.

JSON Format

The expected JSON format follows the Body parameters from the Create a label GitHub Rest API endpoint.

See the following example:

[
  {
    "name": "Bug",                            // <- String
    "description": "Something isn't working", // <- String (max 100 chars, optional)
    "color": "d73a4a"                         // <- String (hexadecimal color code without the leading #) 
  }
  // ...
]

Professional Support

Professional support is available, contact support@jop-software.de for more information.

© 2023, jop-software Inh. Johannes Przymusinski

GLAC - GitHub labels as code is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.

About

Store your labels as code in the repository
1.0.0
Latest

GLAC - GitHub labels as code is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.