From 512bd9dca18987b41a98d7c5a426b3f386bc7aba Mon Sep 17 00:00:00 2001 From: stnamco Date: Mon, 15 Aug 2022 07:36:25 +0900 Subject: [PATCH] Update README.md --- README.md | 49 ++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 48 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 8c5b5a6..2861753 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,49 @@ # add-card-to-project -add issue or pr to github project +just add issue or pr to github project + + +#### Example Usage + +```yaml +name: Add card to project + +on: + issues: + types: + - opened + +jobs: + add-card-to-project: + name: Add issue to project + runs-on: ubuntu-latest + steps: + - name: Example create PR action + id: createPullrequest + uses: peter-evans/create-pull-request@v4 + with: + base: main + branch-suffix: timestamp + title: Example + assignees: ${{ github.actor }} + body: example text + - uses: stNamco/add-card-to-project@v0.0.1 + with: + githubToken: ${{secrets.EXAMPLE_PAT}} + ownerType: user + ownerName: stNamco + projectNumber: 6 + repositoryName: example-issues + issueId: ${{ steps.createPullrequest.outputs.pull-request-number }} +``` + + +### Action inputs + +| Name | Description | +| --- | --- | +| githubToken | `repo` and `project` scoped [Personal Access Token (PAT)](https://docs.github.com/en/github/authenticating-to-github/creating-a-personal-access-token). | +| ownerType | `user` or `organization`. | +| ownerName | user name or organization name. | +| repositoryName | github repository name. | +| projectNumber | github project numeber. | +| issueId | the issue or pr id. |