We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 419b532 commit 7471dc2Copy full SHA for 7471dc2
.github/scripts/pre-push-build.sh
@@ -0,0 +1,20 @@
1
+#!/bin/sh
2
+
3
+BRANCH=$(git rev-parse --abbrev-ref HEAD)
4
+echo "현재 브랜치: $BRANCH"
5
6
+if [ "$BRANCH" = "develop" ]; then
7
+ echo "develop 브랜치 빌드 검사 시작 (spring.profiles.active=dev)..."
8
9
+ ./gradlew clean build -x test -Dspring.profiles.active=dev
10
+ if [ $? -ne 0 ]; then
11
+ echo "빌드 실패! push 차단"
12
+ exit 1
13
+ fi
14
15
+ echo "빌드 성공! push 진행."
16
+else
17
+ echo "$BRANCH 브랜치는 빌드 체크 없이 push 허용"
18
+fi
19
20
+exit 0
0 commit comments