Skip to content

Commit

Permalink
Merge pull request #8 from technote-space/release/v1.0.0
Browse files Browse the repository at this point in the history
Release/v1.0.0
  • Loading branch information
technote-space committed Aug 27, 2019
2 parents 521bbda + b2371b8 commit dd83689
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 9 deletions.
3 changes: 3 additions & 0 deletions .github/card-labeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Backlog:
'In progress':
- 'Status: In Progress'
2 changes: 1 addition & 1 deletion .github/workflows/project_card_moved.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Auto card labeler
uses: technote-space/auto-card-labeler@v0.0.1
uses: technote-space/auto-card-labeler@v1
3 changes: 2 additions & 1 deletion .github/workflows/released.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Release GitHub Actions
uses: technote-space/release-github-actions@v1.0.3
uses: technote-space/release-github-actions@v1
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
ACCESS_TOKEN: ${{ secrets.ACCESS_TOKEN }}
COMMIT_NAME: Technote
COMMIT_EMAIL: technote.space@gmail.com
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Auto card labeler
uses: technote-space/auto-card-labeler@v0.0.1
uses: technote-space/auto-card-labeler@v1
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
```
4 changes: 4 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
name: Auto card labeler
description: GitHub actions to auto label a pull request or an issue based on project card move.
author: technote-space
inputs:
GITHUB_TOKEN:
description: Secret GitHub API token to use for making API requests.
required: true
runs:
using: node12
main: lib/main.js
7 changes: 1 addition & 6 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,7 @@ async function run() {
return;
}

if (typeof process.env.GITHUB_TOKEN === 'undefined' || process.env.GITHUB_TOKEN === '') {
// noinspection ExceptionCaughtLocallyJS
throw new Error(`Input required and not supplied: GITHUB_TOKEN`);
}

const octokit = new GitHub(process.env.GITHUB_TOKEN);
const octokit = new GitHub(getInput('GITHUB_TOKEN', {required: true}));
const config = await getConfig(CONFIG_FILENAME, octokit, context);
if (!Object.keys(config).length) {
signale.warn('There is no valid config file.');
Expand Down

0 comments on commit dd83689

Please sign in to comment.