chore(husky): add pre-push githook for branch naming convention#87
chore(husky): add pre-push githook for branch naming convention#87froggy1014 merged 2 commits intomainfrom
Conversation
|
| Name | Type |
|---|---|
| @sipe-team/input | Patch |
| @sipe-team/badge | Patch |
| @sipe-team/card | Patch |
| @sipe-team/divider | Patch |
| @sipe-team/radio-group | Patch |
| @sipe-team/side | Patch |
| @sipe-team/skeleton | Patch |
| @sipe-team/switch | Patch |
| @sipe-team/tooltip | Patch |
| @sipe-team/typography | Patch |
Click here to learn what changesets are, and how to add one.
Click here if you're a maintainer who wants to add a changeset to this PR
변경 사항 분석Walkthrough이 변경 사항은 Changes
Possibly related PRs
Suggested reviewers
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
Finishing Touches
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
Codecov ReportAll modified and coverable lines are covered by tests ✅ |
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (3)
.husky/pre-push (3)
1-2: 분리된 HEAD 상태 처리 필요현재 구현은 일반적인 브랜치에서는 잘 작동하지만, 분리된 HEAD 상태를 처리하지 않습니다.
다음과 같이 수정하는 것을 추천드립니다:
-BRANCH_NAME=$(git rev-parse --abbrev-ref HEAD) +BRANCH_NAME=$(git symbolic-ref -q --short HEAD || echo "HEAD") +if [ "$BRANCH_NAME" = "HEAD" ]; then + echo "현재 분리된 HEAD 상태입니다. 브랜치에서 작업해주세요." + exit 1 +fi
7-14: 에러 메시지 개선 필요현재 에러 메시지는 기본적인 정보만 제공합니다. 구체적인 예시를 추가하면 사용자가 더 쉽게 이해할 수 있을 것 같습니다.
다음과 같이 수정하는 것을 추천드립니다:
- echo "Error: Invalid branch name format." + echo "오류: 올바르지 않은 브랜치 이름 형식입니다." echo echo "Please rename your branch using:" echo "git branch -m <CATEGORY>/<SUBJECT> or git branch -m <CATEGORY>/<ISSUENUMBER>-<SUBJECT>" echo echo "CATEGORY: feat, fix, hotfix, chore, refactor, release, test, docs, ci, build" + echo + echo "예시:" + echo "- feat/user-login" + echo "- fix/87-memory-leak" + echo "- chore/update-dependencies" echo
17-17: 성공 메시지 추가 권장현재는 성공 시 아무런 메시지 없이 종료됩니다. 사용자에게 브랜치 이름이 유효하다는 피드백을 제공하면 좋을 것 같습니다.
다음과 같이 수정하는 것을 추천드립니다:
+echo "✅ 브랜치 이름이 규칙에 맞습니다: $BRANCH_NAME" exit 0
synuns
left a comment
There was a problem hiding this comment.
이제 브랜치 컨벤션까지!!
완성도가 점점 높아지는 기분이 듭니다~~
Changes
아래 이슈에 기반해서 pre-push 깃훅을 추가해봤습니다.
Visuals
Checklist
Additional Discussion Points
Summary by CodeRabbit