chore: test #15
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Release | |
| on: | |
| push: | |
| branches: | |
| - develop | |
| pull_request: | |
| types: [closed] | |
| branches: | |
| - develop | |
| # 동일한 워크플로우가 동시에 실행되는 것을 방지 | |
| concurrency: ${{ github.workflow }}-${{ github.ref }} | |
| jobs: | |
| create-release-pr: | |
| if: github.event_name == 'push' || github.event.pull_request.merged == true | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v3 | |
| with: | |
| base: main | |
| head: develop | |
| branch: release | |
| title: "🚀 Release: Merge develop to main" | |
| body: | | |
| ## 변경사항 | |
| ${{ github.event_name == 'pull_request' && github.event.pull_request.body || 'Direct push to develop' }} | |
| commit-message: "chore: merge develop to main" | |
| delete-branch: true | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v3 | |
| with: | |
| node-version: 18 | |
| cache: "npm" | |
| - name: Install Dependencies | |
| run: npm ci | |
| - name: Build | |
| run: npm run build | |
| - name: Create Release Pull Request or Publish | |
| id: changesets | |
| uses: changesets/action@v1 | |
| with: | |
| publish: npm run release | |
| title: "🚀 Version Packages" | |
| commit: "chore: version packages" | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |