Skip to content

Commit 98db142

Browse files
authored
Fix the example of how to comment on pull request. (#220)
It doesn't work without granting permissions. https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs
1 parent a549f5e commit 98db142

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

README.md

+4
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,8 @@ Outputs can be used in subsequent steps to comment on the pull request:
8787
defaults:
8888
run:
8989
working-directory: ${{ env.tf_actions_working_dir }}
90+
permissions:
91+
pull-requests: write
9092
steps:
9193
- uses: actions/checkout@v3
9294
- uses: hashicorp/setup-terraform@v2
@@ -153,6 +155,8 @@ Instead of creating a new comment each time, you can also update an existing one
153155
defaults:
154156
run:
155157
working-directory: ${{ env.tf_actions_working_dir }}
158+
permissions:
159+
pull-requests: write
156160
steps:
157161
- uses: actions/checkout@v3
158162
- uses: hashicorp/setup-terraform@v2

0 commit comments

Comments
 (0)