File tree Expand file tree Collapse file tree 2 files changed +9
-2
lines changed
lib/modules/datasource/maven Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Original file line number Diff line number Diff line change 1111 <name >Generic Package</name >
1212 <description >Generic Maven Package</description >
1313 <scm >
14- <url >scm:https://github.com/example/test</url >
14+ <url >scm:https://github.com/example/test/tree/${project.scm.tag} </url >
1515 <connection >scm:git@github.com:example/test.git</connection >
1616 <developerConnection >scm:git@github.com:example/test.git</developerConnection >
1717 </scm >
Original file line number Diff line number Diff line change @@ -276,6 +276,10 @@ function containsPlaceholder(str: string): boolean {
276276 return regEx ( / \$ { .* ?} / g) . test ( str ) ;
277277}
278278
279+ function removeKnownPlaceholders ( str : string ) : string {
280+ return str . replace ( regEx ( / \/ t r e e \/ \$ { [ ^ } ] + } / ) , '' ) ;
281+ }
282+
279283export function getMavenUrl (
280284 dependency : MavenDependency ,
281285 repoUrl : string ,
@@ -454,7 +458,10 @@ export async function getDependencyInfo(
454458 }
455459
456460 const sourceUrl = pomContent . valueWithPath ( 'scm.url' ) ;
457- if ( sourceUrl && ! containsPlaceholder ( sourceUrl ) ) {
461+ if (
462+ sourceUrl &&
463+ ! containsPlaceholder ( removeKnownPlaceholders ( sourceUrl ) )
464+ ) {
458465 result . sourceUrl = sourceUrl
459466 . replace ( regEx ( / ^ s c m : / ) , '' )
460467 . replace ( regEx ( / ^ g i t : / ) , '' )
You can’t perform that action at this time.
0 commit comments