Skip to content

Commit dcf41c6

Browse files
rodion-arrmhdawson
authored andcommitted
Fix "support show" command in order to save dependencies ordering
1 parent c52fa43 commit dcf41c6

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

lib/cli/commands/show.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,9 @@ async function printModule (module, depth, argv) {
2222
console.log(`${' '.repeat(2 * (depth + 1))}${moduleInfo} - ${supportInfo.url}`)
2323
}
2424

25+
// sort child modules
26+
module.children = new Map([...module.children.entries()].sort())
27+
2528
// print info for all of the child modules
2629
for (const child of module.children.values()) {
2730
await printModule(child, depth + 1, argv)

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
"postpublish": "git push origin && git push origin --tags"
2525
},
2626
"dependencies": {
27-
"@npmcli/arborist": "0.0.0-pre.19",
27+
"@npmcli/arborist": "^0.0.0",
2828
"ajv": "^6.11.0",
2929
"better-ajv-errors": "^0.6.7",
3030
"got": "^11.1.3",

0 commit comments

Comments
 (0)