-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Target JDK 1.8 and use sbt-github-actions for snapshot publish
- Loading branch information
1 parent
0d0a247
commit c87feaf
Showing
4 changed files
with
81 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -24,7 +24,7 @@ jobs: | |
matrix: | ||
os: [ubuntu-latest, macos-latest, windows-latest] | ||
scala: [2.12.18] | ||
java: [temurin@11, temurin@17, temurin@21] | ||
java: [temurin@8] | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- name: Ignore line ending differences in git | ||
|
@@ -45,33 +45,79 @@ jobs: | |
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup Java (temurin@11) | ||
if: matrix.java == 'temurin@11' | ||
- name: Setup Java (temurin@8) | ||
if: matrix.java == 'temurin@8' | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: temurin | ||
java-version: 11 | ||
java-version: 8 | ||
cache: sbt | ||
|
||
- name: Setup Java (temurin@17) | ||
if: matrix.java == 'temurin@17' | ||
uses: actions/setup-java@v4 | ||
- name: Check that workflows are up to date | ||
shell: bash | ||
run: sbt '++ ${{ matrix.scala }}' githubWorkflowCheck | ||
|
||
- shell: bash | ||
run: sbt '++ ${{ matrix.scala }}' test scripted | ||
|
||
- name: Compress target directories | ||
shell: bash | ||
run: tar cf targets.tar target theme/target plugin/target project/target | ||
|
||
- name: Upload target directories | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
distribution: temurin | ||
java-version: 17 | ||
cache: sbt | ||
name: target-${{ matrix.os }}-${{ matrix.scala }}-${{ matrix.java }} | ||
path: targets.tar | ||
|
||
publish: | ||
name: Publish Artifacts | ||
needs: [build] | ||
if: github.event_name != 'pull_request' && (github.ref == 'refs/heads/main') | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest] | ||
scala: [2.12.18] | ||
java: [temurin@8] | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- name: Ignore line ending differences in git | ||
if: contains(runner.os, 'windows') | ||
run: git config --global core.autocrlf false | ||
|
||
- name: Setup Java (temurin@21) | ||
if: matrix.java == 'temurin@21' | ||
- name: Configure pagefile for Windows | ||
if: contains(runner.os, 'windows') | ||
uses: al-cheb/[email protected] | ||
with: | ||
minimum-size: 2GB | ||
maximum-size: 8GB | ||
disk-root: 'C:' | ||
|
||
- name: Checkout current branch (full) | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup Java (temurin@8) | ||
if: matrix.java == 'temurin@8' | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: temurin | ||
java-version: 21 | ||
java-version: 8 | ||
cache: sbt | ||
|
||
- name: Check that workflows are up to date | ||
shell: bash | ||
run: sbt '++ ${{ matrix.scala }}' githubWorkflowCheck | ||
- name: Download target directories (2.12.18) | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: target-${{ matrix.os }}-2.12.18-${{ matrix.java }} | ||
|
||
- shell: bash | ||
run: sbt '++ ${{ matrix.scala }}' test scripted | ||
- name: Inflate target directories (2.12.18) | ||
run: | | ||
tar xf targets.tar | ||
rm targets.tar | ||
- name: Publish project | ||
env: | ||
NEXUS_USER: ${{ secrets.NEXUS_USER }} | ||
NEXUS_PW: ${{ secrets.NEXUS_PW }} | ||
run: sbt publish |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters