Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Schoonology/git-lfs-test

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

Git LFS Test

This repository was used while testing this blog post and Git LFS. Specifically, we wanted to make sure we understood what would happen if a client without LFS installed cloned an LFS-enabled repository.

As you might expect, the client with LFS installed downloaded the LFS-tracked binaries during the git clone process, with no additional work on the part of the user. On the client without LFS installed, only the pointer file was downloaded, with no other errors or warnings.

The specific steps taken during testing can be found below. The environments used in testing were:

  • This repo was originally created in OSX.
  • The LFS-enabled environment was a Docker container from the jansauer/docker-lfs image.
  • The non-LFS environment was a Docker container from the samueldebruyn/debian-git image.

More discussion on the topic can be found in the original post.

Steps to create this repository

  1. Created and cloned this GitHub repo normally.
  2. Installed Git LFS to track all JPG files: git lfs track '*.jpg'
  3. Added and committed the new .gitattributes file.
  4. Added a binary for LFS to track: git add binary.jpg
  5. Committed the new image.
  6. Pushed to GitHub.
Git LFS: (1 of 1 files) 606.22 KB / 606.22 KB
Counting objects: 6, done.
Delta compression using up to 8 threads.
Compressing objects: 100% (5/5), done.
Writing objects: 100% (6/6), 704 bytes | 0 bytes/s, done.
Total 6 (delta 1), reused 0 (delta 0)
remote: Resolving deltas: 100% (1/1), done.
To github.com:Schoonology/git-lfs-test.git
   cdc9fb6..5a24879  HEAD -> master

Test with LFS installed

docker run -it jansauer/docker-lfs /bin/sh
...
/ # git clone https://github.com/Schoonology/git-lfs-test.git
Cloning into 'git-lfs-test'...
remote: Counting objects: 9, done.
remote: Compressing objects: 100% (5/5), done.
remote: Total 9 (delta 1), reused 6 (delta 1), pack-reused 0
Unpacking objects: 100% (9/9), done.
Checking connectivity... done.
Downloading binary.jpg (606.22 KB)
/ # cd git-lfs-test/
/git-lfs-test # ls -l
total 612
-rw-r--r--    1 root     root            14 Jan 13 18:24 README.md
-rw-r--r--    1 root     root        620773 Jan 13 18:24 binary.jpg

Test without LFS installed

docker run -it samueldebruyn/debian-git /bin/sh
...
# git clone https://github.com/Schoonology/git-lfs-test.git
Cloning into 'git-lfs-test'...
remote: Counting objects: 9, done.
remote: Compressing objects: 100% (5/5), done.
remote: Total 9 (delta 1), reused 6 (delta 1), pack-reused 0
Unpacking objects: 100% (9/9), done.
Checking connectivity... done.
# cd git-lfs-test
# ls -l
total 8
-rw-r--r-- 1 root root  14 Jan 13 18:29 README.md
-rw-r--r-- 1 root root 131 Jan 13 18:29 binary.jpg
# cat binary.jpg
version https://git-lfs.github.com/spec/v1
oid sha256:6fe2e48ef494b7855e6d8f93c59cf38d38350274e304a9ac35102d5c365ee002
size 620773

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published
Morty Proxy This is a proxified and sanitized view of the page, visit original site.