Skip to content

Commit 81ddd31

Browse files
update config
1 parent 6731406 commit 81ddd31

File tree

1 file changed

+31
-45
lines changed

1 file changed

+31
-45
lines changed

.github/workflows/push.yml

+31-45
Original file line numberDiff line numberDiff line change
@@ -2,53 +2,39 @@ name: Node CI
22

33
on: [push]
44

5+
# Enabled permissions on GITHUB_TOKEN
6+
permissions:
7+
# To be able to push to the repo
8+
contents: write
9+
# To update the pr description with canary info
10+
pull-requests: write
11+
# For pr-check to create a status
12+
statuses: write
13+
# Needed to create PR statuses/checks
14+
checks: write
15+
# To post comments on PRs
16+
issues: write
17+
518
jobs:
6-
build:
19+
release:
720
runs-on: ubuntu-latest
21+
if: "!contains(github.event.head_commit.message, 'ci skip') && !contains(github.event.head_commit.message, 'skip ci')"
22+
steps:
23+
- uses: actions/checkout@v2
824

9-
strategy:
10-
matrix:
11-
node-version: [10.x, 12.x]
25+
- name: Prepare repository
26+
run: git fetch --unshallow --tags
1227

13-
steps:
14-
- uses: actions/checkout@v1
15-
- name: Use Node.js ${{ matrix.node-version }}
16-
uses: actions/setup-node@v1
17-
with:
18-
node-version: ${{ matrix.node-version }}
19-
- name: npm install, build, and lint
20-
run: |
21-
yarn
22-
yarn build
23-
yarn lint
24-
release:
25-
runs-on: ubuntu-latest
28+
- name: Use Node.js 14.x
29+
uses: actions/setup-node@v1
30+
with:
31+
node-version: 14.x
2632

27-
steps:
28-
- uses: actions/checkout@v1
29-
- name: Skip CI
30-
uses: veggiemonk/skip-commit@master
31-
env:
32-
COMMIT_FILTER: skip ci
33-
- name: Prepare repository
34-
env:
35-
GH_TOKEN: ${{ secrets.GH_TOKEN }}
36-
run: |
37-
git checkout "${GITHUB_REF:11}"
38-
git remote rm origin
39-
git remote add origin "https://[email protected]/hipstersmoothie/eslint-formatter-github.git"
40-
git fetch origin
41-
git branch --set-upstream-to origin/master
42-
- name: Use Node.js 12.x
43-
uses: actions/setup-node@v1
44-
with:
45-
node-version: 12.x
46-
- name: Create Release
47-
env:
48-
GH_TOKEN: ${{ secrets.GH_TOKEN }}
49-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
50-
run: |
51-
git remote -v
52-
yarn
53-
yarn build
54-
yarn release
33+
- name: Create Release
34+
env:
35+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
36+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
37+
run: |
38+
yarn
39+
yarn build
40+
yarn release

0 commit comments

Comments
 (0)