Repository navigation
DOC add doc repo cleanup to release process - #32620
Conversation
lesteve
left a comment
There was a problem hiding this comment.
Thanks a few minor questions and comments but this is already very useful.
One question: should we start by doing it at every major release or every minor release? I am not 100% sure how the maintainer templating works.
| {% endif %} | ||
|
|
||
| - The `scikit-learn/scikit-learn.github.io` needs to be cleaned up so that ideally | ||
| it stays <5GB in size. Before doing this, create a fork of the existing repo |
There was a problem hiding this comment.
I guess you also need to sync main on your fork if the idea is to keep the history "just in case"?
There was a problem hiding this comment.
changed this to "new fresh fork"
| # need a non-shallow copy, and using https is much faster than ssh here | ||
| git clone https://github.com/scikit-learn/scikit-learn.github.io.git | ||
| cd scikit-learn.github.io | ||
| git remote add write [email protected]:scikit-learn/scikit-learn.github.io.git |
There was a problem hiding this comment.
Just curious why not use https here too? Full disclosure: I have always used https and never bothered with git clone git@ (mostly for simplicity, for a very long time I was afraid of the complexity of setting up SSH keys 😅)
There was a problem hiding this comment.
This is what I did, I don't want to bother with authentication of https and 2FA every time I clone something, so I setup my keys once, and never do GH authentication again locally.
There was a problem hiding this comment.
I think either would do. The point is not to forget about it.
There was a problem hiding this comment.
Yeah, in practice when the repo is so large, it makes quite a bit of a difference in the time it takes to finish this task
| {% endif %} | ||
|
|
||
| - The `scikit-learn/scikit-learn.github.io` needs to be cleaned up so that ideally | ||
| it stays <5GB in size. Before doing this, create a fork of the existing repo |
There was a problem hiding this comment.
Just curious do you know whether the indicative ~5GB acceptable size is for the .git or for the total size of the git clone. For one commit for scikit-learn .git is at 1.6G, git clone is at 5.2G.
MNE-Python which is using a similar strategy (squash commits every release) for one commit 2.3G git clone 7.6G.
There was a problem hiding this comment.
It's total size of the repo and its history, so includes .git folder. That's the recommendation, but the hard limit is 100GB.
I also don't know, I'm hoping @jeremiedbb will have a look and tell us which templating to do. This file is a lot more confusing to edit for me compared to last time I had a look at it. |
ogrisel
left a comment
There was a problem hiding this comment.
LGTM besides the following question:
| git branch -D main | ||
| # rename current branch to main to replace it | ||
| git branch -m main | ||
| git push --force write main |
There was a problem hiding this comment.
Don't you need to commit anything? Or does git branch -m main creates a commit automatically?
There was a problem hiding this comment.
Yep, forgot to put it here
Looks like right now this is every release which is OK (major and bug-fix), although every major release is probably fine as well, see rendered doc
|
|
Let's merge this one and adapt in the future if needed! |

This adds cleanup of the doc repo to the release process to make sure we do the cleanup periodically not to reach the limit again.
cc @lesteve @jeremiedbb