Skip to content

Commit 2e07665

Browse files
committed
chore(dep): update node and github action dependencies
1 parent 1091527 commit 2e07665

File tree

4 files changed

+18
-12
lines changed

4 files changed

+18
-12
lines changed

.github/workflows/node.js.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ jobs:
1010

1111
steps:
1212
- uses: actions/checkout@v4
13-
- name: Use Node 20
13+
- name: Use Node 22
1414
uses: actions/setup-node@v4
1515
with:
16-
node-version: 20
16+
node-version: 22
1717
- run: npm ci
1818
- run: npm run format:check
1919
- run: npm run build

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
contents: write
2929

3030
steps:
31-
- uses: actions/checkout@v3
31+
- uses: actions/checkout@v4
3232
- uses: jamesgeorge007/github-activity-readme@master
3333
env:
3434
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -73,7 +73,7 @@ jobs:
7373
contents: write
7474
7575
steps:
76-
- uses: actions/checkout@v3
76+
- uses: actions/checkout@v4
7777
- uses: jamesgeorge007/github-activity-readme@master
7878
env:
7979
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

dist/index.js

+10-4
Original file line numberDiff line numberDiff line change
@@ -8920,15 +8920,17 @@ function escapeArgument(arg, doubleEscapeMetaChars) {
89208920
arg = `${arg}`;
89218921

89228922
// Algorithm below is based on https://qntm.org/cmd
8923+
// It's slightly altered to disable JS backtracking to avoid hanging on specially crafted input
8924+
// Please see https://github.com/moxystudio/node-cross-spawn/pull/160 for more information
89238925

89248926
// Sequence of backslashes followed by a double quote:
89258927
// double up all the backslashes and escape the double quote
8926-
arg = arg.replace(/(\\*)"/g, '$1$1\\"');
8928+
arg = arg.replace(/(?=(\\+?)?)\1"/g, '$1$1\\"');
89278929

89288930
// Sequence of backslashes followed by the end of the string
89298931
// (which will become a double quote later):
89308932
// double up all the backslashes
8931-
arg = arg.replace(/(\\*)$/, '$1$1');
8933+
arg = arg.replace(/(?=(\\+?)?)\1$/, '$1$1');
89328934

89338935
// All other backslashes occur literally
89348936

@@ -9005,10 +9007,12 @@ const pathKey = __nccwpck_require__(539)();
90059007
function resolveCommandAttempt(parsed, withoutPathExt) {
90069008
const cwd = process.cwd();
90079009
const hasCustomCwd = parsed.options.cwd != null;
9010+
// Worker threads do not have process.chdir()
9011+
const shouldSwitchCwd = hasCustomCwd && process.chdir !== undefined;
90089012

90099013
// If a custom `cwd` was specified, we need to change the process cwd
90109014
// because `which` will do stat calls but does not support a custom cwd
9011-
if (hasCustomCwd) {
9015+
if (shouldSwitchCwd) {
90129016
try {
90139017
process.chdir(parsed.options.cwd);
90149018
} catch (err) {
@@ -9026,7 +9030,9 @@ function resolveCommandAttempt(parsed, withoutPathExt) {
90269030
} catch (e) {
90279031
/* Empty */
90289032
} finally {
9029-
process.chdir(cwd);
9033+
if (shouldSwitchCwd) {
9034+
process.chdir(cwd);
9035+
}
90309036
}
90319037

90329038
// If we successfully resolved, ensure that an absolute path is returned

package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "github-activity-readme",
3-
"version": "0.4.4",
3+
"version": "0.4.5",
44
"description": "Updates README with the recent GitHub activity of a user",
55
"main": "index.js",
66
"keywords": [],
@@ -12,11 +12,11 @@
1212
"build": "ncc build index.js -o dist"
1313
},
1414
"dependencies": {
15-
"@actions/core": "^1.10.1",
15+
"@actions/core": "^1.11.1",
1616
"actions-toolkit": "^6.0.1"
1717
},
1818
"devDependencies": {
19-
"@vercel/ncc": "^0.38.1",
20-
"prettier": "^3.2.5"
19+
"@vercel/ncc": "^0.38.3",
20+
"prettier": "^3.4.2"
2121
}
2222
}

0 commit comments

Comments
 (0)