Skip to content

Commit

Permalink
Merge pull request bradennapier#44 from bradennapier/beta
Browse files Browse the repository at this point in the history
Release beta
  • Loading branch information
bradennapier authored Aug 12, 2020
2 parents 8c9ac9b + 288f8ba commit f70d9e9
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 6 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,28 @@ on:
- next
- beta
jobs:
pr:
name: Create Release PR
runs-on: ubuntu-latest
steps:
- name: Check For PR
env:
REF: ${{ env.GITHUB_BASE_REF }}
BASE: master
GITHUB_TOKEN: ${{ secrets.BOT_GIT_TOKEN }}
run: |
BRANCH=${GITHUB_REF##*/}
[[ "$BRANCH" == "$BASE" ]] && exit 0;
if [[ "$BRANCH" == "alpha" ]]; then
BASE="beta"
fi
echo "Check If PR exists for $BRANCH --> $BASE"
if [[ "$(gh pr list -R "$GITHUB_REPOSITORY" --base "$BASE" --state open --label "Release $BRANCH")" == "" ]]; then
echo "Creating PR $BRANCH --> $BASE"
RESULT=$(gh api repos/"${GITHUB_REPOSITORY}"/pulls -F head="$BRANCH" -F base="$BASE" -F title="Release $BRANCH" -F body="This PR was generated automatically. Merging it will transition $BRANCH into ${BASE}.")
PR_NUM=$(echo $RESULT | jq -r '.number')
printf '{"labels": ["Release %s"]}' $BRANCH | gh api repos/"${GITHUB_REPOSITORY}"/issues/"${PR_NUM}"/labels --input -
fi
release:
name: Release
runs-on: ubuntu-latest
Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: bradennapier/eslint-plus-action@v3.4.1
- uses: bradennapier/eslint-plus-action@v3.4.2-beta.1
```
## Features
Expand Down Expand Up @@ -131,7 +131,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: bradennapier/eslint-plus-action@v3.4.1
- uses: bradennapier/eslint-plus-action@v3.4.2-beta.1
```

## Examples
Expand All @@ -149,7 +149,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: bradennapier/eslint-plus-action@v3.4.1
- uses: bradennapier/eslint-plus-action@v3.4.2-beta.1
```

### Environment Variables
Expand All @@ -162,7 +162,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: bradennapier/eslint-plus-action@v3.4.1
- uses: bradennapier/eslint-plus-action@v3.4.2-beta.1
env:
NPM_TOKEN: ${{secrets.NPM_TOKEN}}
```
Expand All @@ -175,7 +175,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: bradennapier/eslint-plus-action@v3.4.1
- uses: bradennapier/eslint-plus-action@v3.4.2-beta.1
env:
NPM_TOKEN: ${{secrets.NPM_TOKEN}}
with:
Expand Down
1 change: 1 addition & 0 deletions lib/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@ function processLintResults(engine, report, data) {
else {
rule.annotations.push(annotation);
}
console.warn('ESLint Annotation: ', annotation);
annotations.push(annotation);
}
}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "typescript-action",
"version": "3.4.1",
"version": "3.4.2-beta.1",
"private": true,
"description": "TypeScript template action",
"main": "lib/run.js",
Expand Down
2 changes: 2 additions & 0 deletions src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,8 @@ export function processLintResults(
rule.annotations.push(annotation);
}

console.warn('ESLint Annotation: ', annotation);

annotations.push(annotation);
}
}
Expand Down

0 comments on commit f70d9e9

Please sign in to comment.