Skip to content

Commit 73b963d

Browse files
authored
feat!: Updage node runtime to 16 and update dependencies (#2)
* feat!: Bump node to 16 and update dependencies * fix types * support only node 16 * Add semantic commit check * Add semantic commit check
1 parent df3308a commit 73b963d

File tree

7 files changed

+3910
-5767
lines changed

7 files changed

+3910
-5767
lines changed

.github/dependabot.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
version: 2
2+
updates:
3+
# Enable version updates for npm
4+
- package-ecosystem: 'npm'
5+
# Look for `package.json` and `lock` files in the `root` directory
6+
directory: '/'
7+
# Check the npm registry for updates every day (weekdays)
8+
schedule:
9+
interval: 'daily'
10+
11+
# Maintain dependencies for GitHub Actions
12+
- package-ecosystem: "github-actions"
13+
directory: "/"
14+
schedule:
15+
interval: "daily"

.github/workflows/ci.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@ jobs:
1212
runs-on: ubuntu-latest
1313
strategy:
1414
matrix:
15-
node-version: ["12", "14"]
15+
node-version: ["16"]
1616
steps:
17-
- uses: actions/checkout@v2
17+
- uses: actions/checkout@v3
1818

1919
- name: Cache
20-
if: matrix.node-version == 12
20+
if: matrix.node-version == 16
2121
uses: actions/cache@v2
2222
with:
2323
path: |
@@ -42,7 +42,7 @@ jobs:
4242
run: yarn build && yarn run package
4343

4444
- name: Update docs
45-
uses: npalm/action-docs-action@v1.0.0
45+
uses: npalm/action-docs-action@v1.3.0
4646

4747
- name: Get token
4848
uses: './'

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020

2121
- uses: actions/setup-node@v2
2222
with:
23-
node-version: 14
23+
node-version: 16
2424

2525
- name: Get installation token
2626
uses: './'

.github/workflows/semantic-check.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: "Semantic Check"
2+
3+
on:
4+
pull_request_target:
5+
types:
6+
- opened
7+
- edited
8+
- synchronize
9+
10+
permissions:
11+
contents: read
12+
pull-requests: read
13+
14+
jobs:
15+
main:
16+
name: Semantic Commit Message Check
17+
runs-on: ubuntu-latest
18+
steps:
19+
- uses: actions/checkout@v3
20+
21+
- uses: amannn/action-semantic-pull-request@v5
22+
name: Check PR for Semantic Commit Message
23+
env:
24+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
25+
with:
26+
requireScope: false
27+
validateSingleCommit: true
28+
ignoreLabels: release merge

package.json

Lines changed: 24 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -29,32 +29,33 @@
2929
"license": "MIT",
3030
"dependencies": {
3131
"@actions/core": "^1.2.6",
32-
"@actions/github": "^4.0.0",
33-
"@octokit/auth-app": "^2.11.0"
32+
"@actions/github": "^5.1.1",
33+
"@octokit/auth-app": "^4.0.7",
34+
"yarn": "^1.22.19"
3435
},
3536
"devDependencies": {
36-
"@semantic-release/changelog": "^5.0.1",
37-
"@semantic-release/commit-analyzer": "^8.0.1",
38-
"@semantic-release/exec": "^5.0.0",
39-
"@semantic-release/git": "^9.0.0",
40-
"@semantic-release/github": "^7.2.0",
41-
"@semantic-release/release-notes-generator": "^9.0.1",
42-
"@types/jest": "^26.0.15",
43-
"@types/node": "^14.14.26",
44-
"@typescript-eslint/parser": "^4.15.2",
45-
"@vercel/ncc": "^0.25.1",
46-
"conventional-changelog-conventionalcommits": "^4.5.0",
47-
"eslint": "^7.17.0",
37+
"@semantic-release/changelog": "^6.0.1",
38+
"@semantic-release/commit-analyzer": "^9.0.2",
39+
"@semantic-release/exec": "^6.0.3",
40+
"@semantic-release/git": "^10.0.1",
41+
"@semantic-release/github": "^8.0.6",
42+
"@semantic-release/release-notes-generator": "^10.0.3",
43+
"@types/jest": "^29.2.0",
44+
"@types/node": "^18.11.7",
45+
"@typescript-eslint/parser": "^5.41.0",
46+
"@vercel/ncc": "^0.34.0",
47+
"conventional-changelog-conventionalcommits": "^5.0.0",
48+
"eslint": "^8.26.0",
4849
"eslint-plugin-github": "^4.1.1",
49-
"eslint-plugin-jest": "^24.1.3",
50-
"jest": "^26.6.3",
51-
"jest-circus": "^26.6.3",
52-
"js-yaml": "^3.14.0",
50+
"eslint-plugin-jest": "^27.1.3",
51+
"jest": "^29.2.2",
52+
"jest-circus": "^29.2.2",
53+
"js-yaml": "^4.1.0",
5354
"nock": "^13.0.7",
54-
"prettier": "2.2.1",
55-
"semantic-release": "^17.3.9",
56-
"ts-jest": "^26.4.4",
57-
"ts-node-dev": "^1.1.1",
55+
"prettier": "2.7.1",
56+
"semantic-release": "^19.0.5",
57+
"ts-jest": "^29.0.3",
58+
"ts-node-dev": "^2.0.0",
5859
"typescript": "^4.1.5"
5960
}
60-
}
61+
}

src/main.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ async function run(): Promise<void> {
1616

1717
core.setOutput('token', installationToken);
1818
} catch (error) {
19-
core.debug(error);
20-
core.setFailed(error.message);
19+
core.debug((error as Error).message);
20+
core.setFailed((error as Error).message);
2121
}
2222
}
2323

0 commit comments

Comments
 (0)