Skip to content

Commit

Permalink
[YS-49] chore: CI 스크립트 작성 및 PR 오토 템플릿 추가 (#7)
Browse files Browse the repository at this point in the history
* feat: add ci script

* feat: add pr auto template script

* style: update comment content
  • Loading branch information
Ji-soo708 authored Dec 28, 2024
1 parent 2101be6 commit 814b8c2
Show file tree
Hide file tree
Showing 2 changed files with 52 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/ci-backend.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Java CI with Gradle

on:
push:
branches:
- main
- dev
pull_request:
branches:
- main
- dev

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'

- name: Grant execute permission for gradlew
run: chmod +x gradlew

- name: Build with Gradle
run: ./gradlew clean build
22 changes: 22 additions & 0 deletions .github/workflows/pr-auto-template.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: "Pull Request 오토 템플릿 추가"
on:
pull_request:
branches:
- dev

jobs:
update_pr_templates:
runs-on: ubuntu-latest
steps:
- uses: tzkhan/pr-update-action@v2 # https://github.com/tzkhan/pr-update-action
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
base-branch-regex: 'dev'
head-branch-regex: 'ys-\d+' # Branch에서 Ticket Regex
title-template: '[%headbranch%] ' # PR Title Prefix 템플릿 (티켓 번호) (ex: [YS-1234] ~ )
body-template: | # PR Body suffix 템플릿 (지라 링크)
## 🔗 Jira 티켓
---
https://yappsocks.atlassian.net/browse/%headbranch%
body-update-action: 'suffix'

0 comments on commit 814b8c2

Please sign in to comment.