Skip to content
Open
Show file tree
Hide file tree
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
3 changes: 0 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,13 @@ jobs:
- uses: netlify/pr-labeler-action@v1.0.0
if: startsWith(github.event.pull_request.title, 'fix')
with:
token: '${{ secrets.GITHUB_TOKEN }}'
label: 'type: bug'
- uses: netlify/pr-labeler-action@v1.0.0
if: startsWith(github.event.pull_request.title, 'chore')
with:
token: '${{ secrets.GITHUB_TOKEN }}'
label: 'type: chore'
- uses: netlify/pr-labeler-action@v1.0.0
if: startsWith(github.event.pull_request.title, 'feat')
with:
token: '${{ secrets.GITHUB_TOKEN }}'
label: 'type: feature'
```
2 changes: 2 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ description: 'A GitHub Action to label a Pull Request'
author: netlify
inputs:
token:
default: ${{ github.token }}
description: 'The GITHUB_TOKEN secret'
required: false
label:
description: 'The label to assign to the PR'
runs:
Expand Down
2 changes: 1 addition & 1 deletion dist/index.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import * as github from '@actions/github';

async function main() {
try {
const token = core.getInput('token', { required: true });
const token = core.getInput('token');
const label = core.getInput('label', { required: true });

const pullRequest = github.context.payload.pull_request;
Expand Down