Skip to content

riiid/comment-related-issues

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Repository files navigation

What it is?

It captures CAPITAL-number(ex. ABC-123, EFG-201) from commit messages and append related issues into the PR description.

Usage

name: comment-related-issues

on:
  pull_request:
    branches: ["main"]

jobs:
  report:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
        with:
          fetch-depth: 0
      # for private action
      - name: Checkout private GitHub Action comment-related-issues
        uses: actions/checkout@v2
        with:
          repository: riiid/comment-related-issues
          ref: v0.0.1
          token: ${{ secrets.GITHUB_TOKEN }}
          ssh-key: ${{ secrets.SSH_KEY }}
          path: .github/actions/comment-related-issues
      - uses: ./.github/actions/comment-related-issues
        with:
          tracker: jira
          project-key: TE
          jira-protocol: https
          jira-host: my-jira-host.com
          jira-username: john
          jira-token: ${{ secrets.JIRA_TOKEN }}
          path: ./my-project
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Note: The fetch-depth option in actions/checkout@v2 needs to be set 0 because we need commit logs.

Inputs

Name Required Default Description
tracker [x] Issue tracker name. Available values are jira
project-key [ ] Project key like jira project key
jira-protocol [ ] https Jira protocol. Available values are http and https. Default value is https. Required for Jira.
jira-host [ ] Jira hostname. Required for Jira.
jira-username [ ] Jira username. Required for Jira.
jira-token [ ] Jira token from the Jira account. Required for Jira.
path [ ] . Relative path from git repo's root to where you are interested in.

About

No description, website, or topics provided.

Resources

License

Apache-2.0, MIT licenses found

Licenses found

Apache-2.0
LICENSE-APACHE
MIT
LICENSE-MIT

Stars

Watchers

Forks

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •