jenkinsjenkins-pluginshudson-plugins

Jenkins mercurial plugin polling rules customization


Is there a way to configure jenkins mercurial plugin to poll only tags/branches matching a specific pattern? I.e. I need it to trigger a build only if a new tag with '-dev' suffix has been pushed


Solution

  • Answering my own question

    The field Revision in the jenkins mercurial plugin is the same value one can use in hg log -r <expression> hence all of the expressions available here can be used

    For example to find the latest -dev tag the following expression needs to be entered into the Revision field:

    max(tag("re:\-dev$"))