File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -8,7 +8,10 @@ const addGitSha = (spec, sha) => {
88 return `${ base } #${ sha } `
99 } else {
1010 // don't use new URL for this, because it doesn't handle scp urls
11- return spec . rawSpec . replace ( / # .* $ / , '' ) + `#${ sha } `
11+ // strip the committish with indexOf/slice to avoid a regexp redos
12+ const hashIndex = spec . rawSpec . indexOf ( '#' )
13+ const base = hashIndex === - 1 ? spec . rawSpec : spec . rawSpec . slice ( 0 , hashIndex )
14+ return `${ base } #${ sha } `
1215 }
1316}
1417
Original file line number Diff line number Diff line change 11{
22 "name" : " pacote" ,
3- "version" : " 21.5.0 " ,
3+ "version" : " 21.5.1 " ,
44 "description" : " JavaScript package downloader" ,
55 "author" : " GitHub Inc." ,
66 "bin" : {
2828 "devDependencies" : {
2929 "@npmcli/arborist" : " ^9.0.2" ,
3030 "@npmcli/eslint-config" : " ^6.0.0" ,
31- "@npmcli/template-oss" : " 4.29 .0" ,
31+ "@npmcli/template-oss" : " 5.1 .0" ,
3232 "hosted-git-info" : " ^9.0.0" ,
3333 "mutate-fs" : " ^2.1.1" ,
3434 "nock" : " ^13.2.4" ,
7373 },
7474 "templateOSS" : {
7575 "//@npmcli/template-oss" : " This file is partially managed by @npmcli/template-oss. Edits may be overwritten." ,
76- "version" : " 4.29 .0" ,
76+ "version" : " 5.1 .0" ,
7777 "windowsCI" : false ,
7878 "publish" : " true"
7979 }
Original file line number Diff line number Diff line change 133133 "npm-registry-fetch" : " ^19.1.1" ,
134134 "npm-user-validate" : " ^4.0.0" ,
135135 "p-map" : " ^7.0.4" ,
136- "pacote" : " ^21.5.0 " ,
136+ "pacote" : " ^21.5.1 " ,
137137 "parse-conflict-json" : " ^5.0.1" ,
138138 "proc-log" : " ^6.1.0" ,
139139 "qrcode-terminal" : " ^0.12.0" ,
92779277 "license" : " BlueOak-1.0.0"
92789278 },
92799279 "node_modules/pacote" : {
9280- "version" : " 21.5.0 " ,
9281- "resolved" : " https://registry.npmjs.org/pacote/-/pacote-21.5.0 .tgz" ,
9282- "integrity" : " sha512-VtZ0SB8mb5Tzw3dXDfVAIjhyVKUHZkS/ZH9/5mpKenwC9sFOXNI0JI7kEF7IMkwOnsWMFrvAZHzx1T5fmrp9FQ ==" ,
9280+ "version" : " 21.5.1 " ,
9281+ "resolved" : " https://registry.npmjs.org/pacote/-/pacote-21.5.1 .tgz" ,
9282+ "integrity" : " sha512-KvcJ9iy3crysCsgqc4+PknH/w6jkrp8JN36mpZBPwNaDRwTfMZD37YzRazNstiZUOhuF5pno9f78n9mEJBavwg ==" ,
92839283 "inBundle" : true ,
92849284 "license" : " ISC" ,
92859285 "dependencies" : {
Original file line number Diff line number Diff line change 101101 "npm-registry-fetch" : " ^19.1.1" ,
102102 "npm-user-validate" : " ^4.0.0" ,
103103 "p-map" : " ^7.0.4" ,
104- "pacote" : " ^21.5.0 " ,
104+ "pacote" : " ^21.5.1 " ,
105105 "parse-conflict-json" : " ^5.0.1" ,
106106 "proc-log" : " ^6.1.0" ,
107107 "qrcode-terminal" : " ^0.12.0" ,
You can’t perform that action at this time.
0 commit comments