I would like to trigger a Build on Gitlab when a Git Tag is pushed to the repository. At the same time I would like to increment the version number on a file located on the repository before building it on a runner. My question is . Is it a webhook needed for the purpose ?

1 Answer 1


You don't need a webhook.

You can use the tags keyword with the only/except condition syntax for running jobs in a pipeline.

You then need to implement the job of course, which will do what you need:

  1. take the new tag
  2. update a file with it
  3. commit the new file and push it back to the repo
  4. ... other builds steps ...

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.