Github Actionsでghコマンドを使う
code:yml
name: Comment when opened
on:
issues:
types:
- opened
jobs:
comment:
runs-on: ubuntu-latest
steps:
- run: gh issue comment $ISSUE --body "Thank you for opening this issue!"
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
ISSUE: ${{ github.event.issue.html_url }}
GH_TOKENを設定しておけばトークンで認証して使える
GITHUB_TOKENはrunnerで自動的に払い出される