https://issues.jenkins-ci.org/browse/JENKINS-28335 discusses the request to
publish tags and commits from workflow.

Mark Waite

On Tue, Aug 9, 2016 at 10:40 AM Rob Oxspring <[email protected]> wrote:

> Hi,
>
> I'm using an uptodate Jenkins 2.7.2 and trying to use the new pipeline
> syntax to create a job that will perform a build and then create a tag in
> git if successful.
>
> I was expecting to reuse the GitPublisher but that doesn't seem to be
> available according to the pipeline syntax helper. I assume that means that
> it's not a pipeline compatible build step and not that I just need to
> figure out undocumented syntax to make it work!
>
> Is there a different way I should be going about this?
>
> What changes would be required in the GitPublisher in order to become
> pipeline compatible?
>
> Thanks,
>
> Rob
>
>
>
>
> node() {
>   deleteDir()
>
>   checkout scm
>   java = tool 'JDK8'
>   mvn = tool 'M3'
>
>   withEnv(["JAVA_HOME=${java}"]) {
>     opts = "--batch-mode --fail-at-end"
>     sh "${mvn}/bin/mvn ${opts} install"
>   }
>
>   // if successful
>   //   create git tag:
>   //   archive/publish artifacts: archive 'target/*.zip, target/*.tar.gz'
> }
>
> --
> You received this message because you are subscribed to the Google Groups
> "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/d5d03313-b7f0-4a83-b8e3-5c5dc398f5fc%40googlegroups.com
> <https://groups.google.com/d/msgid/jenkinsci-users/d5d03313-b7f0-4a83-b8e3-5c5dc398f5fc%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAO49JtE-7%3D%3DLt7W_VQHor%3D%2BsOdo7zr5%2BRFztbpd4L%2BWPyB8GKw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to