Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-40529

Prune tags on fetch

XMLWordPrintable

    • Icon: New Feature New Feature
    • Resolution: Fixed
    • Icon: Major Major
    • git-plugin
    • None
    • Git plugin 4.3.0 - June 19, 2020

      The git-plugin doesn't prune tags on fetch and it comes to the situation when there are a lot of unused tags already fetched and stored locally in .git even though that tags in central repository were already removed.

      In cases when the build process is based on tags, old tags could play a role and break the custom build logic.

      To avoid this, there is an option to delete a workspace entirely before build, however it doesn't look like a right and nice solution to clone everything again.

      It would help a lot if there will be an option implemented to prune tags on fetch such as

      # git fetch --prune origin +refs/tags/*:refs/tags/*
      

            nfalco Nikolas Falco
            xeagle Yuriy Zaplavnov
            Votes:
            8 Vote for this issue
            Watchers:
            8 Start watching this issue

              Created:
              Updated:
              Resolved: