Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Git Publisher "target remote name" validation problems, single repo

I am trying to use the Git Publisher plugin to tag a successful build with the $BUILD_TAG, but I cannot figure out a value for the Target remote name that it will accept. If I use the Repository URL in the GIT configuration I'm told, No remote repository configured with the name . I tried naming the configuration and using that as the Target remote name, no luck.

My SCM configuration (company name elided):

  • Repository URL: http://stash.company.com/scm/semsrch/medqp.git
  • Credentials: sebuserro/****** [This is configured by our build team]
  • Name: experiment
  • Branch Specifier: origin/experiment

My Git Publisher configuration:

  • Push Only If Build Succeeds: checked
  • Tag to push: $BUILD_TAG
  • Tag message: $BUILD_URL
  • Create new tag: checked
  • Target remote name: http://stash.company.com/scm/semsrch/medqp.git

There is something about Git that I'm missing here.

Thank you in advance for your help.

like image 707
TreeRex Avatar asked Apr 02 '15 18:04

TreeRex


2 Answers

If your branch name is experiment and remote name is origin, change your SCM and Git Publisher configuration to:

SCM configuration:

  • Name: "origin"
  • Branch Specifier: "*/experiment"

Git Publisher configuration:

  • Target remote name: "origin"

The important thing, is to set the same name for Name parameter in SCM and Target remote name in Git Publisher.

I know it's a bit too late for answer, but maybe someone will find it useful.

like image 118
banshee Avatar answered Oct 11 '22 14:10

banshee


Target remote name: will be "origin"

You can execute shell and generate custom tag and pass the same to git publisher.

like image 41
Balu Avatar answered Oct 11 '22 14:10

Balu