Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

📝 Update docs about token permissions #27

Merged
merged 2 commits into from
Aug 1, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ on:
- labeled
workflow_dispatch:

permissions:
issues: write

jobs:
issue-manager:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -212,6 +215,9 @@ on:
- labeled
workflow_dispatch:

permissions:
issues: write

jobs:
issue-manager:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -278,6 +284,9 @@ on:
- labeled
workflow_dispatch:

permissions:
issues: write

jobs:
issue-manager:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -339,6 +348,21 @@ on:
* This way you can add a label to a PR that was answered long ago, or that was waiting for more comments from the author, reviews, commits, etc. And if the configured delay since the last comment is enough the GitHub action will close the issue right away.
* The `workflow_dispatch` option allows you to run the action manually from the GitHub Actions tab for your repo.

## GitHub Action Permissions

From the examples above you can see a section:

```yml
permissions:
issues: write
```

This is to give the GitHub Action the necessary permissions to write to the issues.

When you add this GitHub Action to a personal repo, you might not need this specific permission.

But when you add it to a repo that belongs to a GitHub organization, depending on the organization default configurations, you might need to explicitly set this permission.

## Motivation

### Closing early
Expand Down