Skip to content

Commit

Permalink
ci: make setup action
Browse files Browse the repository at this point in the history
  • Loading branch information
jangjunha committed Sep 12, 2023
1 parent 3e3b56f commit 6d581d0
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 16 deletions.
23 changes: 23 additions & 0 deletions .github/actions/setup/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Setup Build Environment
description: checkout and setup gradle, java and build plugins
runs:
using: composite
steps:
- name: Checkout ftgo-proto repository
uses: actions/checkout@v4
with:
repository: jangjunha/ftgo-proto
path: ftgo-proto/
- uses: actions/checkout@v4
with:
path: ftgo/

- uses: actions/setup-java@v3
with:
distribution: liberica
java-version: 17
- name: Setup Gradle
uses: gradle/gradle-build-action@v2
- uses: jangjunha/pact-broker-actions/install-plugin@main
with:
source: protobuf
18 changes: 2 additions & 16 deletions .github/workflows/publish-pact.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,24 +12,10 @@ jobs:
run:
working-directory: ftgo/
steps:
- name: Checkout ftgo-proto repository
uses: actions/checkout@v4
with:
repository: jangjunha/ftgo-proto
path: ftgo-proto/
- uses: actions/checkout@v4
with:
path: ftgo/

- uses: actions/setup-java@v3
with:
distribution: liberica
java-version: 17
- name: Setup Gradle
uses: gradle/gradle-build-action@v2
- uses: jangjunha/pact-broker-actions/install-plugin@main
with:
source: protobuf
sparse-checkout: .github
- uses: ./.github/actions/setup

- name: Execute Gradle test
run: ./gradlew -p ftgo-api-gateway test --tests '*PactTest'
Expand Down

0 comments on commit 6d581d0

Please sign in to comment.