Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
git-lfs
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
isgphys
git-lfs
Commits
6901d5bb
Commit
6901d5bb
authored
9 months ago
by
Sven Mäder
Browse files
Options
Downloads
Patches
Plain Diff
Document git lfs usage
parent
e73062e6
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
README.markdown
+48
-1
48 additions, 1 deletion
README.markdown
img/git-lfs-settings.png
+3
-0
3 additions, 0 deletions
img/git-lfs-settings.png
with
51 additions
and
1 deletion
README.markdown
+
48
−
1
View file @
6901d5bb
git-lfs
git-lfs
=======
=======
https://docs.gitlab.com/ee/topics/git/lfs/
Documentation: https://gitlab.phys.ethz.ch/help/topics/git/lfs/index
usage
-----
Enable
**Large File Storage**
in: Gitlab > Group > Settings > General > Projects in this group can use Git LFS:

Install
`git-lfs`
(pre-installed on managed Linux workstations):
```
bash
apt
install
git-lfs
```
In the git repo clone:
```
bash
```
bash
git lfs track
"*.png"
git lfs track
"*.png"
git lfs track
"*.jpg"
git lfs track
"*.jpg"
git add .gitattributes
git commit
-m
'Store png and jpg in git lfs'
```
```
From now on the lfs tracked files will be uploaded as lfs objects:
```
bash
+rda:~/git/test/git-lfs[±]
$
git add
-A
+rda:~/git/test/git-lfs[±]
$
git status
On branch master
Your branch is up to
date
with
'origin/master'
.
Changes to be committed:
(
use
"git restore --staged <file>..."
to unstage
)
modified: README.markdown
new file: img/git-lfs-settings.png
+rda:~/git/test/git-lfs[±]
$
git commit
-m
'Document git lfs usage'
+rda:~/git/test/git-lfs[+]
$
git push
Locking support detected on remote
"origin"
.
Consider enabling it with:
$
git config lfs.https://gitlab.phys.ethz.ch/isgphys/git-lfs.git/info/lfs.locksverify
true
Uploading LFS objects: 100%
(
2/2
)
, 318 KB | 0 B/s,
done
.
Enumerating objects: 9,
done
.
Counting objects: 100%
(
9/9
)
,
done
.
Delta compression using up to 8 threads
Compressing objects: 100%
(
7/7
)
,
done
.
Writing objects: 100%
(
7/7
)
, 843 bytes | 843.00 KiB/s,
done
.
Total 7
(
delta 0
)
, reused 0
(
delta 0
)
, pack-reused 0
To gitlab.phys.ethz.ch:isgphys/git-lfs.git
c65d50b..e73062e master -> master
```
users
-----




This diff is collapsed.
Click to expand it.
img/git-lfs-settings.png
0 → 100644
LFS
+
3
−
0
View file @
6901d5bb
130 B
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment