-
Notifications
You must be signed in to change notification settings - Fork 277
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
47 additions
and
27 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 |
---|---|---|
|
@@ -6,7 +6,7 @@ on: | |
tags: | ||
- '*' | ||
pull_request: | ||
|
||
jobs: | ||
test: | ||
strategy: | ||
|
@@ -40,17 +40,35 @@ jobs: | |
fail-fast: false | ||
matrix: | ||
os: [macOS-latest, ubuntu-latest] | ||
libc: [default, musl] | ||
exclude: | ||
- os: macOS-latest | ||
libc: musl | ||
include: | ||
- os: macOS-latest | ||
url: https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-20.0.0/graalvm-ce-java11-darwin-amd64-20.0.0.tar.gz | ||
artifact: scalafmt-macos | ||
- os: ubuntu-latest | ||
url: https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-20.0.0/graalvm-ce-java11-linux-amd64-20.0.0.tar.gz | ||
artifact: scalafmt-linux | ||
libc: default | ||
artifact: scalafmt-linux-glibc | ||
env: | ||
- NATIVE_IMAGE_STATIC: true | ||
- os: ubuntu-latest | ||
libc: musl | ||
artifact: scalafmt-linux-musl | ||
env: | ||
- NATIVE_IMAGE_STATIC: true | ||
- NATIVE_IMAGE_MUSL: ${GITHUB_WORKSPACE}/bundle | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: olafurpg/setup-scala@v6 | ||
- run: jabba install [email protected]=tgz+${{ matrix.url }} | ||
- uses: olafurpg/setup-scala@v7 | ||
with: | ||
java-version: [email protected] | ||
- if: matrix.libc == 'musl' | ||
name: Install musl bundle | ||
run: | | ||
wget https://github.com/gradinac/musl-bundle-example/releases/download/v1.0/musl.tar.gz | ||
tar xvf musl.tar.gz | ||
- run: bin/build-native-image.sh | ||
env: | ||
CI: true | ||
|
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 |
---|---|---|
@@ -1,8 +1,5 @@ | ||
set -eux | ||
# NOTE(olafur): for some reason `jabba use ...` doesn't seem to work on GH Actions | ||
export JAVA_HOME=$(jabba which --home [email protected]) | ||
export PATH=$JAVA_HOME/bin:$PATH | ||
echo $JAVA_HOME | ||
which gu | ||
gu install native-image | ||
sbt cli/graalvm-native-image:packageBin | ||
|
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
13 changes: 13 additions & 0 deletions
13
...rc/main/resources/META-INF/native-image/org.scalafmt/scalafmt-cli/native-image.properties
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 |
---|---|---|
@@ -0,0 +1,13 @@ | ||
Args=--no-server \ | ||
-Dscalafmt.native-image=true \ | ||
--no-fallback \ | ||
--enable-http \ | ||
--enable-https \ | ||
--enable-all-security-services \ | ||
--install-exit-handlers \ | ||
--initialize-at-build-time \ | ||
--verbose \ | ||
-H:EnableURLProtocols=http,https \ | ||
-H:+TraceClassInitialization \ | ||
-H:+RemoveSaturatedTypeFlows \ | ||
-H:+ReportExceptionStackTraces |
File renamed without changes.