Skip to content

Commit 1f93db3

Browse files
authored
read package registry from string
* fix: read package registry from string * fix: yaml syntax of dependabot.yml * fix: stop normalizing registry information
1 parent d7e3ce3 commit 1f93db3

File tree

5 files changed

+166
-128
lines changed

5 files changed

+166
-128
lines changed

.github/dependabot.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ updates:
66
interval: "weekly"
77
day: "sunday"
88
time: "06:00"
9-
timezone: "Europe/Berlin"`
9+
timezone: "Europe/Berlin"
1010
# minor and patch updates for webpack and webpack's typescript
1111
# types are updated manually as they will break the build
1212
# rather often`
@@ -15,4 +15,4 @@ updates:
1515
update-types: ["version-update:semver-minor", "version-update:semver-patch"]
1616
- dependency-name: "@types/webpack"
1717
update-types: ["version-update:semver-minor", "version-update:semver-patch"]
18-
open-pull-requests-limit: 50
18+
open-pull-requests-limit: 50

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,8 @@
4646
"test:e2e": "jest --runInBand --testPathPattern test/e2e",
4747
"test:unit": "jest --runInBand --testPathPattern test/unit --verbose",
4848
"test:watch": "jest --runInBand --testPathPattern test/unit --watch",
49-
"test:ci": "cross-env CI=true jest --runInBand --verbose --colors && codecov -t $CODECOV_TOKEN"
49+
"test:ci": "cross-env CI=true jest --runInBand --verbose --colors",
50+
"posttest:ci": "codecov -t $CODECOV_TOKEN"
5051
},
5152
"dependencies": {
5253
"chalk": "^4.1.0",

src/LicenseMetaAggregator.ts

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -84,11 +84,8 @@ export default class LicenseMetaAggregator implements ILicenseMetaAggregator {
8484
public getRepository(meta: Pick<IPackageJson, 'repository'>): string {
8585
if (meta.repository && meta.repository.url) {
8686
return meta.repository.url
87-
.replace('git+ssh://git@', 'git://')
88-
.replace('git+https://github.com', 'https://github.com')
89-
.replace('git://github.com', 'https://github.com')
90-
.replace('[email protected]:', 'https://github.com/')
91-
.replace(/\.git$/, '')
87+
} else if (typeof meta.repository === 'string') {
88+
return meta.repository
9289
}
9390

9491
return null

0 commit comments

Comments
 (0)