Skip to content

Please consider moving gh-pages to another repository and/or reduce the size of the branch #2048

Closed

Description

@vlsi

The clone of https://github.com/junit-team/junit5 takes a lot. It downloads ~500MiB+, and the resulting repository is full of various pdf files.

Here are the top consumers:

hash bytes path
fffea6e6616e 3812203 docs/5.5.1/user-guide/index.pdf
d3f697d9c019 3812203 docs/5.5.0/user-guide/index.pdf
30d099b3af05 3812203 docs/5.5.2/user-guide/index.pdf
6267c2a59eb1 3812011 docs/snapshot/user-guide/index.pdf
...

and so on.

It does impact both regular development experience (as everybody is used to just git clone $url), and it does impact GitHub Actions CI: it takes 1minute for the "checkout action".

Note: GitHub Action could probably be improved to skip gh-pages branch, however, the issue for humans would sill be there.

  1. Are PDFs required? Could they be pushed somewhere else? Do all the snapshots need to be stored in the main repository?

  2. Could you please consider the use of noTimestamp for the javadoc? It will avoid printing the timestamps, thus it would reduce the changes in the html files.
    See Use notimestamp for JavaDoc and notimestamp+noversionstamp for GroovyDoc gradle/gradle#8619

Sample:

withType<Javadoc>().configureEach {
                (options as StandardJavadocDocletOptions).apply {
                    noTimestamp.value = true

Activity

  1. vlsi commented on Oct 7, 2019

    @vlsi
    ContributorAuthor

    Adding fetch-depth: 50 might help (to a degree), however it looks like the current GitHub Actions always fetches all the branches in the repository: actions/checkout#22 :(

    AFAIK https://github.com/meetup/express-checkout does not help (it does not understand pull requests)

  2. marcphilipp commented on Oct 8, 2019

    @marcphilipp
    Member

    I agree that we should improve the current situation. 🙂

    We'll have to be careful not to break existing URLs, i.e. junit.org/junit5/... should continue to work.

    Does anyone know what would happen if we moved the gh_pages branch to a new junit5 subdir in https://github.com/junit-team/junit-team.github.io?

  3. vlsi commented on Oct 8, 2019

    @vlsi
    ContributorAuthor

    Just wondering: do you need all the Git history for gh-pages?
    What if gh-pages is truncated (e.g. to keep 10 recent commits only)

  4. marcphilipp commented on Oct 8, 2019

    @marcphilipp
    Member

    I think that would be ok. Or we could keep the manual commits and squash all others?

  5. added this to the 5.6 M1 milestone on Oct 8, 2019
  6. vlsi commented on Oct 8, 2019

    @vlsi
    ContributorAuthor

    Or we could keep the manual commits and squash all others?

    It could make sense. For instance, if the latest commit is automatic, then amend it + force-push-with-lease.

  7. modified the milestones: 5.6 M1, 5.6 M2 on Oct 10, 2019
  8. marcphilipp commented on Nov 21, 2019

    @marcphilipp
    Member

    I created a script based on one I found on StackOverflow that squashes subsequent commits with the same message. The total number of commits on the gh-pages branch would go down from 3347 to 331.

    @junit-team/junit-lambda Are you ok with me force-pushing that to gh-pages? Everyone who previously checked out the branch would have to do a hard reset in their clone/fork.

  9. sormuras commented on Nov 21, 2019

    @sormuras
    Member

    👍

    Pruning old or even all versions of committed PDF files would shrink the repository size even further.

  10. self-assigned this
    on Dec 1, 2019
  11. 16 remaining items

  12. vlsi commented on Jun 4, 2021

    @vlsi
    ContributorAuthor

    Just in case, actions/checkout no longer fetches all branches and tags, so it is fast.

  13. removed this from the milestone on Jun 19, 2021
  14. stale commented on Jun 19, 2022

    @stale

    This issue has been automatically marked as stale because it has not had recent activity. Given the limited bandwidth of the team, it will be automatically closed if no further activity occurs. Thank you for your contribution.

  15. stale commented on Jul 11, 2022

    @stale

    This issue has been automatically closed due to inactivity. If you have a good use case for this feature, please feel free to reopen the issue.

  16. vlsi commented on Jul 11, 2022

    @vlsi
    ContributorAuthor

    I believe it is still relevant

  17. added this to the 5.14.0 milestone on Oct 23, 2026
  18. marcphilipp commented on Oct 23, 2026

    @marcphilipp
    Member

    The gh-pages branch was moved to a separate repo last year https://github.com/junit-team/docs.junit.org so it no longer weighs down Git clones.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions