Skip to content

Commit

Permalink
Merge pull request #59 from snuhcs-course/feat/github-action
Browse files Browse the repository at this point in the history
make CI scripts for android & springboot
  • Loading branch information
thisisWooyeol authored Nov 20, 2023
2 parents 2c7064e + 48e43ce commit febf810
Show file tree
Hide file tree
Showing 7 changed files with 241 additions and 112 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/android.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Android CI

on:
push:
branches: [ "develop", "main" ]
pull_request:
branches: [ "develop", "main" ]

jobs:
build:

runs-on: ubuntu-latest
defaults:
run:
shell: bash
working-directory: ./android

steps:
- uses: actions/checkout@v4
- name: set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'
cache: gradle

- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Add API_BASE_URL to local.properties
run: echo "API_BASE_URL= \"${{ secrets.API_BASE_URL }}\"" >> local.properties
- name: Build with Gradle
run: ./gradlew clean build
- name: Test with Gradle
run: ./gradlew test
32 changes: 32 additions & 0 deletions .github/workflows/springboot.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Springboot CI

on:
push:
branches: [ "develop", "main" ]
pull_request:
branches: [ "develop", "main" ]

jobs:
build:

runs-on: ubuntu-latest
defaults:
run:
shell: bash
working-directory: ./springboot

steps:
- uses: actions/checkout@v4
- name: set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'
cache: gradle

- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Build with Gradle
run: ./gradlew clean build
- name: Test with Gradle
run: ./gradlew test
1 change: 1 addition & 0 deletions android/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,4 @@
.externalNativeBuild
.cxx
local.properties
!gradle/wrapper/gradle-wrapper.jar
Binary file added android/gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion android/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#Sat Oct 07 23:02:30 KST 2023
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.0-bin.zip
networkTimeout=10000
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading

0 comments on commit febf810

Please sign in to comment.