Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delete untracked tags on fetch #4811

Merged

Conversation

stsewd
Copy link
Member

@stsewd stsewd commented Oct 25, 2018

Close #4258

We are using ubuntu 18.04 on both community and commercial sites, so we are good to use this feature available on git>=2.17.0 https://git-scm.com/docs/git-fetch/2.17.0#git-fetch---prune-tags

@stsewd
Copy link
Member Author

stsewd commented Oct 25, 2018

Travis is building with ubuntu 14, so we have git 2.15.1 :/ I can skip the test, or maybe just run the test outside travis.

@ericholscher
Copy link
Member

Interesting, I didn't realize Travis was on such an old Ubuntu. Not sure the best approach -- I wonder if we can install a newer git on Travis or something.

@codecov
Copy link

codecov bot commented Oct 30, 2018

Codecov Report

Merging #4811 into master will not change coverage.
The diff coverage is 100%.

@@           Coverage Diff           @@
##           master    #4811   +/-   ##
=======================================
  Coverage   76.33%   76.33%           
=======================================
  Files         158      158           
  Lines        9968     9968           
  Branches     1258     1258           
=======================================
  Hits         7609     7609           
  Misses       2018     2018           
  Partials      341      341
Impacted Files Coverage Δ
readthedocs/vcs_support/backends/git.py 80.35% <100%> (ø) ⬆️

@stsewd stsewd force-pushed the delete-untracked-tags-on-fetch branch from 9921e9e to 64b8e09 Compare October 30, 2018 01:23
@stsewd
Copy link
Member Author

stsewd commented Oct 30, 2018

I managed to install a recent version (the one we support) of git on travis, build time looks good

Someone from the travis team pointed me out that we can use just apt-get 🎉

@stsewd stsewd requested a review from a team October 30, 2018 01:37
Copy link
Member

@humitos humitos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent! 😍

@@ -1,21 +1,33 @@
# -*- coding: utf-8 -*-

from __future__ import (
absolute_import, division, print_function, unicode_literals)
absolute_import,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we are deprecating Python2 we should remove these imports and also configure .isort to not add them anymore.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

@ericholscher ericholscher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! 👍

@ericholscher ericholscher merged commit 70fee48 into readthedocs:master Nov 1, 2018
@ericholscher
Copy link
Member

Confirmed we have --prune-tags on the servers 👍

@stsewd stsewd deleted the delete-untracked-tags-on-fetch branch November 1, 2018 15:04

# We still have all branches and tags in the local repo
self.assertEqual(
set(['v01', 'v02']),
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just realized that I wrote this code... I should have written {'v01', 'v02'} 🤷‍♂️

@ericholscher
Copy link
Member

I see the --prune-tags deleting tags: https://readthedocs.org/projects/docs/builds/8062273/, but I still see the tags in RTD.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants