Note
- Projects, the all-new projects experience, is now available. For more information about Projects, see "About Projects."
- You can only create a new project (classic) for an organization, repository, or user that already has at least one project (classic). If you're unable to create a project (classic), create a project instead.
Note
GitHub-hosted runners are not currently supported on GitHub Enterprise Server. You can see more information about planned future support on the GitHub public roadmap.
Introduction
This tutorial demonstrates how to use the alex-page/github-project-automation-plus
action to automatically move an issue to a specific column on a project (classic) when the issue is assigned. For example, when an issue is assigned, you can move it into the In Progress
column your project (classic).
In the tutorial, you will first make a workflow file that uses the alex-page/github-project-automation-plus
action. Then, you will customize the workflow to suit your needs.
Creating the workflow
-
Choose a repository where you want to apply this project management workflow. You can use an existing repository that you have write access to, or you can create a new repository. For more information about creating a repository, see "Creating a new repository."
-
In your repository, choose a project (classic). You can use an existing project, or you can create a new project. For more information about creating a project, see "Creating a project (classic)."
-
In your repository, create a file called
.github/workflows/YOUR_WORKFLOW.yml
, replacingYOUR_WORKFLOW
with a name of your choice. This is a workflow file. For more information about creating new files on GitHub, see "Creating new files." -
Copy the following YAML contents into your workflow file.
YAML # This workflow uses actions that are not certified by GitHub. # They are provided by a third-party and are governed by # separate terms of service, privacy policy, and support # documentation. # GitHub recommends pinning actions to a commit SHA. # To get a newer version, you will need to update the SHA. # You can also reference a tag or branch, but the action may change without warning. name: Move assigned card on: issues: types: - assigned jobs: move-assigned-card: runs-on: ubuntu-latest steps: - uses: alex-page/github-project-automation-plus@7ffb872c64bd809d23563a130a0a97d01dfa8f43 with: project: Docs Work column: In Progress repo-token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
# This workflow uses actions that are not certified by GitHub. # They are provided by a third-party and are governed by # separate terms of service, privacy policy, and support # documentation. # GitHub recommends pinning actions to a commit SHA. # To get a newer version, you will need to update the SHA. # You can also reference a tag or branch, but the action may change without warning. name: Move assigned card on: issues: types: - assigned jobs: move-assigned-card: runs-on: ubuntu-latest steps: - uses: alex-page/github-project-automation-plus@7ffb872c64bd809d23563a130a0a97d01dfa8f43 with: project: Docs Work column: In Progress repo-token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
-
Customize the parameters in your workflow file:
- Change the value for
project
to the name of your project (classic). If you have multiple projects (classic) with the same name, thealex-page/github-project-automation-plus
action will act on all projects with the specified name. - Change the value for
column
to the name of the column where you want issues to move when they are assigned. - Change the value for
repo-token
:- Create a personal access token (classic) with the
repo
scope. For more information, see "Managing your personal access tokens." - Store this personal access token as a secret in your repository. For more information about storing secrets, see "Using secrets in GitHub Actions."
- In your workflow file, replace
PERSONAL_ACCESS_TOKEN
with the name of your secret.
- Create a personal access token (classic) with the
- Change the value for
-
Commit your workflow file to the default branch of your repository. For more information, see "Creating new files."
Testing the workflow
Whenever an issue in your repository is assigned, the issue will be moved to the specified project (classic) column. If the issue is not already on the project (classic), it will be added to the project (classic).
If your repository is user-owned, the alex-page/github-project-automation-plus
action will act on all projects in your repository or personal account that have the specified project name and column. Likewise, if your repository is organization-owned, the action will act on all projects in your repository or organization that have the specified project name and column.
Test your workflow by assigning an issue in your repository.
- Open an issue in your repository. For more information, see "Creating an issue."
- Assign the issue. For more information, see "Assigning issues and pull requests to other GitHub users."
- To see the workflow run that assigning the issue triggered, view the history of your workflow runs. For more information, see "Viewing workflow run history."
- When the workflow completes, the issue that you assigned should be added to the specified project (classic) column.
Next steps
- To learn more about additional things you can do with the
alex-page/github-project-automation-plus
action, like deleting or archiving project cards, visit thealex-page/github-project-automation-plus
action documentation.