Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions .husky/post-checkout
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# 현재 브랜치와 이전 브랜치의 pnpm-lock.yaml 파일의 변경 여부를 확인하는 함수
check_pnpm_lock_changes() {
local previous_head=$1
local new_head=$2

# pnpm-lock.yaml 파일의 변경 여부를 확인
git diff --name-only "$previous_head" "$new_head" | grep -q "pnpm-lock.yaml"
}

# 이전 HEAD와 새 HEAD를 인자로 받아옴
previous_head="$1"
new_head="$2"

# 이전 HEAD가 비어 있으면 초기 체크아웃이므로 무시
if [ -z "$previous_head" ]; then
exit 0
fi

# pnpm-lock.yaml 파일이 변경되었는지 확인
if check_pnpm_lock_changes "$previous_head" "$new_head"; then
echo "pnpm-lock.yaml 파일이 변경되었습니다. pnpm install을 실행합니다."
pnpm install
else
echo "pnpm-lock.yaml 파일이 변경되지 않았습니다. pnpm install을 건너뜁니다."
fi
6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@
"dist:mac:intel:notarize": "./scripts/build-mac-intel.sh",
"dist:mac:universal:notarize": "./scripts/build-mac-universal.sh",
"dist:win": "pnpm transpile:electron && pnpm build:electron && electron-builder --win --x64",
"dist:linux": "pnpm transpile:electron && pnpm build:electron && electron-builder --linux --x64"
"dist:linux": "pnpm transpile:electron && pnpm build:electron && electron-builder --linux --x64",
"prepare": "husky"
},
"dependencies": {
"@remix-run/router": "^1.17.0",
Expand All @@ -42,7 +43,7 @@
"react": "^18.3.1",
"react-datepicker": "^7.3.0",
"react-dom": "^18.3.1",
"react-lottie": "^1.2.4",
"react-lottie": "^1.2.10",
"react-router-dom": "^6.24.0",
"socket.io-client": "^4.7.5",
"timezone": "^1.0.23"
Expand All @@ -69,6 +70,7 @@
"eslint-plugin-react": "^7.34.3",
"eslint-plugin-react-hooks": "^4.6.2",
"eslint-plugin-react-refresh": "^0.4.7",
"husky": "^9.1.7",
"msw": "^2.7.0",
"postcss": "^8.4.39",
"prettier": "^3.3.2",
Expand Down
42 changes: 26 additions & 16 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions public/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading