Skip to content

Github Action to automate the attachment of Issues to Projects

Notifications You must be signed in to change notification settings

ZiZasaurus/project-bot

 
 

Repository files navigation

Issues to Project Github Action

Lint and Test

This Github Action automated the the addition of issues to a given Github Project. It uses the Github GraphQL API under the hood, and is compatible with the recently revamped projects.

Setup

This action will need to authenticate to get access to your repositories and projects via the Github API. For this, create a Personal Access Token and store it as a Github secret in the repository where your actions are going to run. The script expects a GITHUB_API_TOKEN environment variable containing your token, regardless of the name you choose for your secret (see example below).

Inputs

project_url

Required URL of the Github project that issues should be added to. Examples:

Example usage

In your workflow file under ./.github/workflows:

name: Add Issues to Project

on:
  issues:
    types: [opened]
env:
  GITHUB_API_TOKEN: ${{ secrets.MY_API_TOKEN }}

jobs:
  add_to_project:
    runs-on: ubuntu-latest
    steps:
    - name: Assign new issues to the project
      uses: tcassou/project-bot@1.0.0
      with:
        project_url: 'https://github.com/orgs/foo/projects/123'

About

Github Action to automate the attachment of Issues to Projects

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 99.0%
  • Dockerfile 1.0%