You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Elliotte Rusty Harold (Jira)" <ji...@apache.org> on 2019/12/20 14:43:00 UTC

[jira] [Updated] (MRELEASE-927) Releasing flat multi-module projects using git

     [ https://issues.apache.org/jira/browse/MRELEASE-927?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Elliotte Rusty Harold updated MRELEASE-927:
-------------------------------------------
    Priority: Minor  (was: Major)

> Releasing flat multi-module projects using git
> ----------------------------------------------
>
>                 Key: MRELEASE-927
>                 URL: https://issues.apache.org/jira/browse/MRELEASE-927
>             Project: Maven Release Plugin
>          Issue Type: Bug
>          Components: prepare
>    Affects Versions: 2.5.1
>         Environment: Apache Maven 3.2.1 (ea8b2b07643dbb1b84b6d16e1f08391b666bc1e9; 2014-02-14T18:37:52+01:00)
> Maven home: C:\maven\apache-maven-3.2.1
> Java version: 1.6.0_26, vendor: Sun Microsystems Inc.
> Java home: C:\jdk\1.6.0-26\jre
> Default locale: fr_FR, platform encoding: cp1252
> OS name: "windows 7", version: "6.1", arch: "x86", family: "windows"
>            Reporter: Antoine
>            Assignee: Mark Struberg
>            Priority: Minor
>
> As suggest by [~rfscholte], I've cloned the MRELEASE-767 which has not been resoved in the 2.5 version.
> When releasing a project as follows wit Git :
> ./parent/pom.xml
> ./module-a/pom.xml
> ./module-b/pom.xml
> From the parent directory, with an scm config in the parent pom.xml (only) as follows:
> {code}
> <scm>
>   <connection>scm:git:ssh://github.com/repox.git</connection>
>   <developerConnection>scm:git:ssh://github.com/repox.git</developerConnection>
>   <tag>master</tag>
>   <url>https://github.com/view/repox.git</url>
> </scm>
> {code}
> In org/apache/maven/shared/release/util/ReleaseUtils.java:182 it does this indiscriminately:
> url = realignScmUrl( parentLevels, url );
> This will trim the repo url from 'ssh://github.com/repox.git' -> 'ssh://github.com', which will cause a failure when pushing the tag.
> This type of realignment is not appropriate when using a git scm type.
> Error message while releasing:
> {quote}
> [INFO] Tagging release with the label repox-2.2.0...
> [INFO] Executing: /bin/sh -c cd /data/jenkins/slaves/slave-xxxx/workspace/repox-ci && git tag -F /tmp/maven-scm-861690979.commit repox-2.2.0
> [INFO] Working directory: /data/jenkins/slaves/slave-xxxx/workspace/repox-ci
> [INFO] Executing: /bin/sh -c cd /data/jenkins/slaves/slave-xxx/workspace/repox-ci && git push sh://github.com/repox refs/tags/repox-2.2.0
> ...
> Waiting for Jenkins to finish collecting data
> mavenExecutionResult exceptions not empty
> message : Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.5.1:prepare (default-cli) on project repox: Unable to tag SCM
> Provider message:
> The git-push command failed.
> Command output:
> fatal: remote error: Remote URL invalid
> A repository could not be determined from the remote URL. Please confirm the
> clone URL in Stash and try again. URL suffix: '/repox'
> fatal: Could not read from remote repository.
> Please make sure you have the correct access rights
> and the repository exists.
> {quote}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)