diff-lockfiles 1.0.2 → 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +5 -0
- package/bin/diff-lockfiles.js +3 -7
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
package/bin/diff-lockfiles.js
CHANGED
|
@@ -8,19 +8,15 @@ import { diff, print } from '../lib/index.js';
|
|
|
8
8
|
const execPromise = promisify(exec);
|
|
9
9
|
const version = '1.0.2';
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
const output = await execPromise(`git diff ${a} ${b} --name-only | grep package-lock.json`);
|
|
11
|
+
async function lockFiles(a, b) {
|
|
12
|
+
const output = await execPromise(`git diff ${a} ${b} --name-only | grep 'package-lock.json$'`);
|
|
13
13
|
const lines = output.stdout;
|
|
14
14
|
const list = lines.trim().split(/\r\n|\r|\n/);
|
|
15
15
|
|
|
16
|
-
if (output.stderr.trim !== '') {
|
|
17
|
-
// console.error(output.stderr.trim);
|
|
18
|
-
}
|
|
19
|
-
|
|
20
16
|
return list;
|
|
21
17
|
};
|
|
22
18
|
|
|
23
|
-
|
|
19
|
+
async function lockFileString(maxBuffer, branch, filename) {
|
|
24
20
|
const output = await execPromise(`git show ${branch}:${filename}`, { maxBuffer: maxBuffer });
|
|
25
21
|
const lines = output.stdout.trim();
|
|
26
22
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "diff-lockfiles",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.3",
|
|
4
4
|
"description": "a diff for package-lock.json files",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -20,12 +20,12 @@
|
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
22
|
"chalk": "^5.3.0",
|
|
23
|
-
"commander": "^
|
|
23
|
+
"commander": "^12.0.0",
|
|
24
24
|
"semver": "^7.5.4",
|
|
25
25
|
"table": "^6.8.1"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
|
-
"eslint": "^
|
|
28
|
+
"eslint": "^9.0.0",
|
|
29
29
|
"jest": "^29.6.2"
|
|
30
30
|
}
|
|
31
31
|
}
|