Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tag-master ignores git tag errors #72

Closed
schmid-hanspeter opened this issue Apr 27, 2017 · 3 comments
Closed

tag-master ignores git tag errors #72

schmid-hanspeter opened this issue Apr 27, 2017 · 3 comments

Comments

@schmid-hanspeter
Copy link

schmid-hanspeter commented Apr 27, 2017

In TagMasterMojo the return value of the call to provider.tag(..) is ignored. The following fix takes this return value into account and produces an error log and exception exactly like maven's scm plugin would:

final TagScmResult tagScmResult = provider.tag(repository, new ScmFileSet(project.getBasedir()), sanitizedTag, tagParams);
if (!tagScmResult.isSuccess()) {
    getLog().error("Provider message:");
    getLog().error(tagScmResult.getProviderMessage());
    getLog().error("Command output:");
    getLog().error(tagScmResult.getCommandOutput());

    throw new MojoFailureException(tagScmResult.getProviderMessage());
}

I have had tag-master silently fail on me because of, for example, a duplicate tag.

@bvarner
Copy link
Contributor

bvarner commented May 1, 2017

Care to send this as a PR? :-)

schmid-hanspeter pushed a commit to schmid-hanspeter/gitflow-helper-maven-plugin that referenced this issue May 3, 2017
@schmid-hanspeter
Copy link
Author

PR sent :-)

bvarner added a commit that referenced this issue May 18, 2017
issue #72: honour return value of provider.tag()
@bvarner
Copy link
Contributor

bvarner commented May 18, 2017

Thanks for the submission!
It's merged to development.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants