Skip to content

rivethealth/action-cached-lfs-checkout

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

72 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GitHub action: Cached LFS checkout

Storing (large) binary files in Git trees is not recommended because any change to the file will result in a re-upload of the entire file when pushing, increasing the size of the Git repository. When updating a 100 MB file 100 times, your repository will be 10 GB in size!

As a remedy, there is Git LFS which stores certain files only as pointers in the Git tree, downloading the actual data from somewhere else when pulling. The repository size remains small.

GitHub applies some fees when the total amount of LFS downloads surpasses 1GB. Unfortunately, even gh-actions runs, when used with

- name: Checkout code
  uses: actions/checkout@v4
  with:
    lfs: true

count towards that limit. To cache the LFS downloads, you can instead use this action. Simply replace the above by

- name: Cached LFS checkout
  uses: rivethealth/[email protected]
  # Use these to explicitly include/exclude files:
  # with:
  #   include: "*"
  #   exclude: ""

Check it out on the GitHub Marketplace!

Further reading

License

The scripts and documentation in this project are released under the MIT License.

About

GitHub checkout action with LFS files pulled from cache

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Just 100.0%