버전문제 수정
This commit is contained in:
+17
-5
@@ -1,11 +1,12 @@
|
||||
#!/usr/bin/env bash
|
||||
# Desktop/Frontend 변경 push 시 semver bump 필수 (plain git push 차단)
|
||||
# frontend/backend/desktop/shared 변경 push 시 semver bump 필수
|
||||
set -euo pipefail
|
||||
|
||||
ROOT="$(git rev-parse --show-toplevel 2>/dev/null || pwd)"
|
||||
cd "$ROOT"
|
||||
|
||||
DESKTOP_PATHS='^(desktop/|frontend/|scripts/(build-desktop|jenkins-desktop|publish-desktop|bump-desktop))'
|
||||
# shellcheck disable=SC1091
|
||||
source "$ROOT/scripts/desktop-version-scope.sh"
|
||||
|
||||
read_local_version() {
|
||||
"$ROOT/scripts/read-desktop-version.sh" 2>/dev/null || echo "0.0.0"
|
||||
@@ -36,7 +37,7 @@ while read -r _local_ref local_sha _remote_ref remote_sha; do
|
||||
range="${remote_sha}..${local_sha}"
|
||||
fi
|
||||
|
||||
if ! git diff --name-only "$range" 2>/dev/null | grep -Eq "$DESKTOP_PATHS"; then
|
||||
if ! desktop_version_diff_affects_app "$range"; then
|
||||
continue
|
||||
fi
|
||||
|
||||
@@ -49,10 +50,21 @@ while read -r _local_ref local_sha _remote_ref remote_sha; do
|
||||
|
||||
echo ""
|
||||
echo "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━"
|
||||
echo " Desktop/Frontend 변경 push — semver bump 가 필요합니다."
|
||||
echo " Desktop 앱 영향 변경(frontend/backend/desktop/shared)"
|
||||
echo " push — semver bump 가 필요합니다."
|
||||
echo " 로컬 v${local_ver} ≤ 원격 v${remote_ver}"
|
||||
echo ""
|
||||
echo " 다음 명령으로 bump + push + Jenkins 빌드:"
|
||||
affected="$(desktop_version_list_affected_in_range "$range" | head -5 | sed 's/^/ /')"
|
||||
if [[ -n "$affected" ]]; then
|
||||
echo " 변경 예:"
|
||||
echo "$affected"
|
||||
count="$(desktop_version_list_affected_in_range "$range" | wc -l | tr -d ' ')"
|
||||
if [[ "$count" -gt 5 ]]; then
|
||||
echo " ... 외 $((count - 5))개 파일"
|
||||
fi
|
||||
echo ""
|
||||
fi
|
||||
echo " bump + push + Jenkins Desktop 빌드:"
|
||||
echo " ./scripts/push-with-desktop-version.sh"
|
||||
echo ""
|
||||
echo " bump 만:"
|
||||
|
||||
Reference in New Issue
Block a user