mirror of
https://github.com/gitbucket/gitbucket.git
synced 2026-01-06 07:40:01 +01:00
Bumps [actions/setup-java](https://github.com/actions/setup-java) from v1 to v2. - [Release notes](https://github.com/actions/setup-java/releases) - [Commits](https://github.com/actions/setup-java/compare/v1...8764a52df183aa0ccea74521dfd9d506ffc7a19a) Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: kenji yoshida <6b656e6a69@gmail.com>
38 lines
942 B
YAML
38 lines
942 B
YAML
name: build
|
|
|
|
on: [push, pull_request]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 30
|
|
strategy:
|
|
matrix:
|
|
java: [8, 11]
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Cache
|
|
uses: actions/cache@v2.1.4
|
|
env:
|
|
cache-name: cache-sbt-libs
|
|
with:
|
|
path: |
|
|
~/.ivy2/cache
|
|
~/.sbt
|
|
~/.cache/coursier/v1
|
|
key: build-${{ env.cache-name }}-${{ hashFiles('build.sbt') }}
|
|
- name: Set up JDK
|
|
uses: actions/setup-java@v2
|
|
with:
|
|
java-version: ${{ matrix.java }}
|
|
distribution: adopt
|
|
- name: Run tests
|
|
run: sbt scalafmtSbtCheck scalafmtCheck test:scalafmtCheck test
|
|
- name: Build executable
|
|
run: sbt executable
|
|
- name: Upload artifacts
|
|
uses: actions/upload-artifact@v2
|
|
with:
|
|
name: gitbucket-java${{ matrix.java }}-${{ github.sha }}
|
|
path: ./target/executable/gitbucket.*
|