Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bump Node.js v16 #434

Merged
merged 3 commits into from
Jan 12, 2022
Merged
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
2 changes: 1 addition & 1 deletion .github/workflows/reviewdog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:

- uses: actions/setup-node@v2
with:
node-version: "12"
node-version: "16.x"
cache: 'npm'
- run: npm ci
- uses: reviewdog/action-eslint@v1
Expand Down
8 changes: 8 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ jobs:
- name: disable auto CRLF
run: git config --global core.autoCRLF false
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: "16.x"
cache: 'npm'
- run: npm ci
- run: npm run build
- run: npm test
Expand All @@ -45,6 +49,10 @@ jobs:
id: ${{ steps.create_release.outputs.id }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: "16.x"
cache: 'npm'
- run: npm ci
- run: npm run build
- run: npm run pack
Expand Down
2 changes: 1 addition & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ outputs:
browser_download_url:
description: 'The URL users can navigate to in order to download the uploaded asset'
runs:
using: 'node12'
using: 'node16'
main: 'dist/index.js'
branding:
icon: 'package'
Expand Down
4 changes: 2 additions & 2 deletions src/upload-release-asset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -298,10 +298,10 @@ const regexUploadUrl = new RegExp(
);
export function parseUploadUrl(rawurl: string): Release {
const match = rawurl.match(regexUploadUrl);
const groups = match?.groups;
if (!groups) {
if (!match || !match.groups) {
throw new Error(`failed to parse the upload url: ${rawurl}`);
}
const groups = match.groups;
return {
owner: groups["owner"],
repo: groups["repo"],
Expand Down
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"compilerOptions": {
"target": "es2019", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019' or 'ESNEXT'. */
"target": "es2021", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019' or 'ESNEXT'. */
"module": "commonjs", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */
"outDir": "./lib", /* Redirect output structure to the directory. */
"rootDir": "./src", /* Specify the root directory of input files. Use to control the output directory structure with --outDir. */
Expand Down