From 44058c0886966353462f9709b72d2ac9e3cb89a0 Mon Sep 17 00:00:00 2001 From: TaeSeung Yoo <59465914+gudusol@users.noreply.github.com> Date: Fri, 17 Jan 2025 00:12:05 +0900 Subject: [PATCH] setting: Issue & PR templates, github workflows (#4) --- .github/ISSUE_TEMPLATE/bug_issue.yml | 33 ++++++++++++++++ .github/ISSUE_TEMPLATE/feature_issue.yml | 25 ++++++++++++ .github/pull_request_template.md | 50 ++++++++++++++++++++++++ .github/workflows/pre-production.yml | 32 +++++++++++++++ .github/workflows/production.yml | 32 +++++++++++++++ 5 files changed, 172 insertions(+) create mode 100644 .github/ISSUE_TEMPLATE/bug_issue.yml create mode 100644 .github/ISSUE_TEMPLATE/feature_issue.yml create mode 100644 .github/pull_request_template.md create mode 100644 .github/workflows/pre-production.yml create mode 100644 .github/workflows/production.yml diff --git a/.github/ISSUE_TEMPLATE/bug_issue.yml b/.github/ISSUE_TEMPLATE/bug_issue.yml new file mode 100644 index 000000000..a44d8e439 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_issue.yml @@ -0,0 +1,33 @@ +name: '버그 제보' +description: Bug Issue 작성 기본 양식입니다. +labels: ['🐞 Fix'] +title: '[fix] ' +body: + - type: markdown + attributes: + value: | + 작성 예시 : "[fix] 버튼 컴포넌트 버그 수정" + - type: textarea + id: bug-description + attributes: + label: 버그 설명 + description: 버그가 언제/어떻게 발생했는지 명확하게 적어주세요. + placeholder: 설명을 적어주세요. + validations: + required: true + - type: textarea + id: reproduction + attributes: + label: 재현 방법 + description: 버그가 재현되는 상황을 설명해주세요. + placeholder: 설명을 적어주세요. + validations: + required: true + - type: textarea + id: expected + attributes: + label: 기대했던 정상 동작 + description: 기대했던 정상적인 동작에 대해서 설명해주세요. + placeholder: 설명을 적어주세요. + validations: + required: true diff --git a/.github/ISSUE_TEMPLATE/feature_issue.yml b/.github/ISSUE_TEMPLATE/feature_issue.yml new file mode 100644 index 000000000..e9ab468fd --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_issue.yml @@ -0,0 +1,25 @@ +name: '기능 추가' +description: 기능 추가 Issue 작성 양식입니다. +labels: ['✨ Feature'] +title: '[feat] ' +body: + - type: markdown + attributes: + value: | + 작성 예시 : "[feat] 버튼 컴포넌트 만들기" + - type: textarea + id: feature-description + attributes: + label: 작업 설명 + description: 어떠한 기능을 추가하시는 건지 적어주세요. + placeholder: 설명을 적어주세요. + validations: + required: true + - type: textarea + id: approach + attributes: + label: 접근 방법 + description: 고려하신 방법이나, 접근에 대해서 설명해주세요. + placeholder: 설명을 적어주세요. + validations: + required: true diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 000000000..45495c1ac --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,50 @@ + + + + + +## 📌 Related Issue Number + + + +- Closes #1 + +--- + +## Checklist + +- [ ] 🎋 base 브랜치를 제대로 설정했나요? +- [ ] 🖌️ PR 제목은 형식에 맞게 잘 작성했나요? +- [ ] 🏗️ 빌드는 성공했나요? (pnpm build) +- [ ] 🧹 불필요한 코드는 제거했나요? e.g. console.log +- [ ] 🙇‍♂️ 리뷰어를 지정했나요? +- [ ] 🏷️ 라벨은 등록했나요? + +--- + +## ✅ Key Changes + +> 이번 PR에서 작업한 내용을 간략히 설명해주세요 + +1. 내용1 + - 설명 +2. 내용2 + - 설명 + +--- + +## 💡 New Insights & Learnings + +- + +--- + +## 📢 To Reviewers + +- + +--- + +## 📸 Screenshot or Video (Optional) + + diff --git a/.github/workflows/pre-production.yml b/.github/workflows/pre-production.yml new file mode 100644 index 000000000..418d6766a --- /dev/null +++ b/.github/workflows/pre-production.yml @@ -0,0 +1,32 @@ +name: Synchronize to forked repo +on: + push: + branches: + - pre-production + +jobs: + sync: + name: Sync forked repo + runs-on: ubuntu-latest + + steps: + - name: Checkout pre-production + uses: actions/checkout@v4 + with: + token: ${{ secrets.FORKED_REPO_TOKEN }} + fetch-depth: 0 + ref: pre-production + + - name: Add remote-url + run: | + git remote add forked-repo https://gudusol:${{ secrets.FORKED_REPO_TOKEN }}@github.com/gudusol/mopl + git config user.name gudusol + git config user.email ${{ secrets.EMAIL }} + + - name: Push changes to forked-repo + run: | + git push -f forked-repo pre-production + + - name: Clean up + run: | + git remote remove forked-repo \ No newline at end of file diff --git a/.github/workflows/production.yml b/.github/workflows/production.yml new file mode 100644 index 000000000..5be09a7c0 --- /dev/null +++ b/.github/workflows/production.yml @@ -0,0 +1,32 @@ +name: Synchronize to forked repo +on: + push: + branches: + - production + +jobs: + sync: + name: Sync forked repo + runs-on: ubuntu-latest + + steps: + - name: Checkout production + uses: actions/checkout@v4 + with: + token: ${{ secrets.FORKED_REPO_TOKEN }} + fetch-depth: 0 + ref: production + + - name: Add remote-url + run: | + git remote add forked-repo https://gudusol:${{ secrets.FORKED_REPO_TOKEN }}@github.com/gudusol/mopl + git config user.name gudusol + git config user.email ${{ secrets.EMAIL }} + + - name: Push changes to forked-repo + run: | + git push -f forked-repo production + + - name: Clean up + run: | + git remote remove forked-repo