Download the Git LFS client for your platform. Instructions in this topic are valid for Git LFS client 1.3 and later. Once you have the LFS set up, you can use extended checkout URL, select the file types you'd like Git LFS to manage, create a commit by adding binary file and technical file (.gitattributes) and finally push the files to remote repositories.
For downloading Git LFS client, see Git Large File Storage page.
Working with LFS over HTTP/HTTPS (without replication)
Example:
git clone http://product_developer@ctf-centos72-dev-box.collab.net/gerrit/test_repo && cd "test_repo" && git config user.name "Nancy S." && git config user.email "nancy@example.com" && curl -o .git/hooks/commit-msg http://product_developer@ctf-centos72-dev-box.collab.net/gerrit/tools/hooks/commit-msg && chmod +x .git/hooks/commit-msg
The following command tracks all .jpg images in a given working directory.
Working with LFS over SSH
git clone -c 'lfs.url=http://product_developer@ctf-centos72-dev-box.collab.net/gerrit/test_repo.git/info/lfs' ssh://product_developer@ctf-centos72-dev-box.collab.net:29418/test_repo && cd "test_repo" && git config user.name "Nancy S." && git config user.email "nancy@example.com" && scp -P 29418 product_developer@ctf-centos72-dev-box.collab.net:hooks/commit-msg .git/hooks/
Working with LFS (with replication)
git clone -c 'lfs.url=http://product_developer@ctf-centos72-dev-box.collab.net/gerrit/test_repo.git/info/lfs' http://product_developer@ctf-centos72-replica.collab.net/gerrit/test_repo && cd "test_repo" && git config user.name "Nancy S." && git config user.email "nancy@example.com" && git config url."http://ctf-centos72-replica.collab.net/gerrit".insteadOf "http://ctf-centos72-dev-box.collab.net/gerrit" && git config url."http://product_developer@ctf-centos72-replica.collab.net/gerrit".insteadOf "http://product_developer@ctf-centos72-dev-box.collab.net/gerrit" && git config url."http://product_developer@ctf-centos72-dev-box.collab.net/gerrit".pushInsteadOf "http://product_developer@ctf-centos72-replica.collab.net/gerrit" && curl -o .git/hooks/commit-msg http://product_developer@ctf-centos72-replica.collab.net/gerrit/tools/hooks/commit-msg && chmod +x .git/hooks/commit-msg
git clone -c 'lfs.url=http://product_developer@ctf-centos72-dev-box.collab.net/gerrit/test_repo.git/info/lfs' ssh://product_developer@ctf-centos72-replica.collab.net:29418/test_repo && cd "test_repo" && git config user.name "Nancy S." && git config user.email "nancy@example.com" && git config url."ssh://ctf-centos72-replica.collab.net:29418".insteadOf "ssh://ctf-centos72-dev-box.collab.net:29418" && git config url."ssh://product_developer@ctf-centos72-replica.collab.net:29418".insteadOf "ssh://product_developer@ctf-centos72-dev-box.collab.net:29418" && git config url."ssh://product_developer@ctf-centos72-dev-box.collab.net:29418".pushInsteadOf "ssh://product_developer@ctf-centos72-replica.collab.net:29418" && scp -P 29418 product_developer@ctf-centos72-replica.collab.net:hooks/commit-msg
Copyright 2016 CollabNet Corporation | Site Feedback | Terms of Use | Privacy Policy | Copyright and Trademark | Support