diff --git a/.github/workflows/ci-build.yml b/.github/workflows/ci-build.yml new file mode 100644 index 0000000000..6630beb060 --- /dev/null +++ b/.github/workflows/ci-build.yml @@ -0,0 +1,37 @@ +name: CI Build +on: + pull_request: + branches: [ 'master' ] + +jobs: + build: + name: CI Build on ${{ matrix.os }} + runs-on: ${{ matrix.os }} + timeout-minutes: 20 + strategy: + matrix: + include: + - os: ubuntu-latest + - os: macos-latest + - os: windows-latest + steps: + - uses: actions/checkout@v2 + - uses: coursier/setup-action@v1.2.0-M3 + apps: sbtn + - uses: coursier/cache-action@v6 + + - name: Build + run: sbtn compile + + - uses: actions/cache@v3 + with: + path: | + ~/.cache/scalablytyped/tests/artifacts + ~/.cache/scalablytyped/test-artifacts + key: ${{ runner.os }}-test-cache-v1 + + - name: Build and test + run: sbtn test + + - name: scalafmt + run: sbtn scalafmtCheck diff --git a/.github/workflows/release-snapshot.yml b/.github/workflows/release-snapshot.yml new file mode 100644 index 0000000000..d27eb2a1e6 --- /dev/null +++ b/.github/workflows/release-snapshot.yml @@ -0,0 +1,21 @@ +# note that the proper release is made manually with the release script because it's +# a heavy operation (builds all demo repos) +# that's why we don't trigger on tag +name: Release snapshot +on: + push: + branches: [ 'master' ] +jobs: + release-snapshot: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: coursier/setup-action@v1.2.0-M3 + apps: sbtn + - uses: coursier/cache-action@v6 + + - name: Build native image (non-windows) + run: sbtn test scalafmtCheck + + - name: publish snapshot + run: sbt ci-release