Skip to content

Commit

Permalink
chore: add support for git-lfs
Browse files Browse the repository at this point in the history
  • Loading branch information
ifiokjr committed Jun 19, 2019
1 parent 3b5ef55 commit 393a6ed
Show file tree
Hide file tree
Showing 10 changed files with 26 additions and 2 deletions.
6 changes: 6 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
*.png filter=lfs diff=lfs merge=lfs -text
*.gif filter=lfs diff=lfs merge=lfs -text
*.sketch filter=lfs diff=lfs merge=lfs -text
*.jpeg filter=lfs diff=lfs merge=lfs -text
*.jpg filter=lfs diff=lfs merge=lfs -text
*.ico filter=lfs diff=lfs merge=lfs -text
6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -202,9 +202,11 @@
},
"husky": {
"hooks": {
"post-checkout": "echo $HUSKY_GIT_STDIN | support/hooks/post-checkout-lfs $HUSKY_GIT_PARAMS",
"post-commit": "echo $HUSKY_GIT_STDIN | support/hooks/post-commit-lfs $HUSKY_GIT_PARAMS",
"post-merge": "echo $HUSKY_GIT_STDIN | support/hooks/post-merge-lfs $HUSKY_GIT_PARAMS && yarn if-config ignoredHooks.postMerge yarn",
"pre-commit": "yarn if-config ignoredHooks.preCommit lint-staged",
"pre-push": "yarn if-config ignoredHooks.prePush yarn checks",
"post-merge": "yarn if-config ignoredHooks.postMerge yarn"
"pre-push": "echo $HUSKY_GIT_STDIN | support/hooks/pre-push-lfs $HUSKY_GIT_PARAMS && yarn if-config ignoredHooks.prePush yarn checks"
}
},
"jest": {
Expand Down
Binary file modified support/assets/01-hearts-are-lovely.gif
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified support/assets/epic-typing-mode-example.gif
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified support/assets/ui-twitter-example.gif
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified support/assets/wysiwyg.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions support/hooks/post-checkout-lfs
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh

command -v git-lfs >/dev/null 2>&1 || { echo >&2 "\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting .git/hooks/post-checkout.\n"; exit 2; }
git lfs post-checkout "$@"
4 changes: 4 additions & 0 deletions support/hooks/post-commit-lfs
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh

command -v git-lfs >/dev/null 2>&1 || { echo >&2 "\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting .git/hooks/post-commit.\n"; exit 2; }
git lfs post-commit "$@"
4 changes: 4 additions & 0 deletions support/hooks/post-merge-lfs
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh

command -v git-lfs >/dev/null 2>&1 || { echo >&2 "\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting .git/hooks/post-merge.\n"; exit 2; }
git lfs post-merge "$@"
4 changes: 4 additions & 0 deletions support/hooks/pre-push-lfs
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh

command -v git-lfs >/dev/null 2>&1 || { echo >&2 "\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting .git/hooks/pre-push.\n"; exit 2; }
git lfs pre-push "$@"

0 comments on commit 393a6ed

Please sign in to comment.