19 lines
523 B
Bash
Executable File
19 lines
523 B
Bash
Executable File
#!/usr/bin/env bash
|
|
# Desktop semver pre-push hook 설치
|
|
set -euo pipefail
|
|
|
|
ROOT="$(cd "$(dirname "$0")/.." && pwd)"
|
|
HOOK_SRC="$ROOT/scripts/hooks/pre-push"
|
|
GIT_HOOK="$ROOT/.git/hooks/pre-push"
|
|
|
|
if [[ ! -d "$ROOT/.git" ]]; then
|
|
echo "ERROR: git repo 가 아닙니다: $ROOT" >&2
|
|
exit 1
|
|
fi
|
|
|
|
cp "$HOOK_SRC" "$GIT_HOOK"
|
|
chmod +x "$GIT_HOOK"
|
|
echo "[install-desktop-git-hooks] pre-push hook 설치됨"
|
|
echo " frontend/backend/desktop/shared 변경 push 시 bump 필수"
|
|
echo " → ./scripts/push-with-desktop-version.sh"
|