Skip to content
Snippets Groups Projects
# Using https://github.com/evilz/vscode-reveal
theme : "black"
# https://github.com/hakimel/reveal.js/tree/master/css/theme
transition: "slide"
# transition: "zoom"
highlightTheme: "darkula"

# parallaxBackgroundImage: "background.jpg"
# parallaxBackgroundSize: "6784px 2151px"
# parallaxBackgroundHorizontal: "1000px"
# parallaxBackgroundVertical: "1000px"

Git LFS @ SSEC

Nick Bearson


Who is this for?

  • Algorithm developers tweaking input datasets - these rarely get versioned well, if at all.

  • Software developers who want to preserve test results for future regression tests.

  • Anyone who wants to keep & version data next to their code!


What is Git LFS?

--

Git LFS is an extension for Git which lets you split large binary files into two:

  1. A Git LFS cache pointer (small, text) which gets versioned & stored alongside your code.

  2. The actual file is sent to a Git LFS store which the cache pointer references.

Think of it like emailing someone a URL instead of attaching an entire file.

--

Git LFS Diagrammed: Animation Image credit: Github.com


How Do I Use It?

--

git lfs install

git lfs track "my_large_dataset.hdf"
git lfs track "*.nc"

git add .gitattributes

git add my_large_dataset.hdf another_file.nc

git commit -m "Add my datasets using Git LFS"

git push origin master
  • After the initial install & track commands, you can use the repository like you would any other.

  • Remember to track any new, large binary-ish files before you commit them!

--

Other Features

  • File Locking
git lfs track "*.nc" --lockable
git lfs lock my.nc
git lfs unlock my.nc
  • Faster Clones - perform a git checkout before downloading from the LFS store
git lfs clone

Provider Storage Quota
Gitlab.com 10 GB
GitHub.com 1 GB free, $5 / 50 GB after
Bitbucket.com 1 GB soft cap, 2 GB hard cap
gitlab.ssec.wisc.edu ∞? (talk to TC)

--

Gitlab.com

--

GitHub.com

--

Bitbucket


An Example

--

https://gitlab.ssec.wisc.edu/geocat/geocat-ancillary

--

Geocat Ancillary Repo

--

Geocat Ancillary Repo


Resources

https://www.atlassian.com/git/tutorials/git-lfs

https://git-lfs.github.com/

https://github.com/git-lfs/git-lfs/wiki/Tutorial