diff --git a/.githooks/post-checkout b/.githooks/post-checkout new file mode 100755 index 0000000..cab40f2 --- /dev/null +++ b/.githooks/post-checkout @@ -0,0 +1,3 @@ +#!/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 "$@" diff --git a/.githooks/post-commit b/.githooks/post-commit new file mode 100755 index 0000000..9443f41 --- /dev/null +++ b/.githooks/post-commit @@ -0,0 +1,3 @@ +#!/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 "$@" diff --git a/.githooks/post-merge b/.githooks/post-merge new file mode 100755 index 0000000..828b708 --- /dev/null +++ b/.githooks/post-merge @@ -0,0 +1,3 @@ +#!/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 "$@" diff --git a/.githooks/pre-push b/.githooks/pre-push index 12e74f1..a0116db 100755 --- a/.githooks/pre-push +++ b/.githooks/pre-push @@ -1,5 +1,5 @@ #!/bin/bash - +# check for WIP commits wips=$(git log --oneline --no-decorate | grep -i wip ) wips_n=$(echo "$wips" | wc -l) LOCKFILE=/tmp/githook.allow_wip @@ -14,3 +14,7 @@ if [[ ! -f $LOCKFILE && -n "$wips" ]]; then * ) echo -e "\naborting."; exit 1;; esac fi + +# git-lfs stuff +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 "$@" diff --git a/.gitignore b/.gitignore index 4d4d9af..4f7355b 100644 --- a/.gitignore +++ b/.gitignore @@ -15,6 +15,10 @@ !.config/btop/** !.config/kitty !.config/kitty/** +!.config/zed +!.config/zed/** +!.githooks +!.githooks/** !.config/rustfmt/** !.config/rustfmt/ !.gitignore