Compare commits
13 Commits
fniephaus/
...
fniephaus/
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a312beff36 | ||
|
|
cfa19cdd20 | ||
|
|
dc8a7ea391 | ||
|
|
8623f5e13e | ||
|
|
23e0acf4b9 | ||
|
|
eec48106e0 | ||
|
|
0f48fc0abd | ||
|
|
3716035e2a | ||
|
|
2a24120090 | ||
|
|
39a82c0b2c | ||
|
|
62b95e60c7 | ||
|
|
a19d2ab4f7 | ||
|
|
319b5062ea |
4
.github/workflows/check-dist.yml
vendored
4
.github/workflows/check-dist.yml
vendored
@@ -36,7 +36,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Setup Node.js
|
- name: Setup Node.js
|
||||||
id: setup-node
|
id: setup-node
|
||||||
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5.0.0
|
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6.0.0
|
||||||
with:
|
with:
|
||||||
node-version-file: .node-version
|
node-version-file: .node-version
|
||||||
cache: npm
|
cache: npm
|
||||||
@@ -70,7 +70,7 @@ jobs:
|
|||||||
- if: ${{ failure() && steps.diff.outcome == 'failure' }}
|
- if: ${{ failure() && steps.diff.outcome == 'failure' }}
|
||||||
name: Upload Artifact
|
name: Upload Artifact
|
||||||
id: upload
|
id: upload
|
||||||
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
|
||||||
with:
|
with:
|
||||||
name: dist
|
name: dist
|
||||||
path: dist/
|
path: dist/
|
||||||
|
|||||||
854
.github/workflows/ci.yml
vendored
854
.github/workflows/ci.yml
vendored
@@ -20,7 +20,7 @@ jobs:
|
|||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
||||||
- name: Setup Node.js
|
- name: Setup Node.js
|
||||||
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5.0.0
|
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6.0.0
|
||||||
with:
|
with:
|
||||||
node-version-file: .node-version
|
node-version-file: .node-version
|
||||||
cache: npm
|
cache: npm
|
||||||
@@ -35,345 +35,299 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
INPUT_GITHUB_TOKEN: ${{ github.token }} # for core.getInput()
|
INPUT_GITHUB_TOKEN: ${{ github.token }} # for core.getInput()
|
||||||
|
|
||||||
# test-action:
|
test-action:
|
||||||
# name: GraalVM
|
name: GraalVM
|
||||||
# runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
# env:
|
env:
|
||||||
# # Skip builds that require a GDS token but have no access to one (e.g., secrets are unavailable in PR runs)
|
# Skip builds that require a GDS token but have no access to one (e.g., secrets are unavailable in PR runs)
|
||||||
# PASSES_GDS_TOKEN_CHECK: ${{ !matrix.set-gds-token || secrets.GDS_TOKEN != '' }}
|
PASSES_GDS_TOKEN_CHECK: ${{ !matrix.set-gds-token || secrets.GDS_TOKEN != '' }}
|
||||||
# strategy:
|
strategy:
|
||||||
# matrix:
|
matrix:
|
||||||
# java-version: ['25', '21', '17', '20', 'dev']
|
java-version: ['25', '21', '17', '20', 'dev']
|
||||||
# distribution: ['graalvm', 'graalvm-community']
|
distribution: ['graalvm', 'graalvm-community']
|
||||||
# os: [
|
os: [
|
||||||
# ubuntu-latest, # Linux on Intel
|
ubuntu-latest, # Linux on Intel
|
||||||
# ubuntu-22.04-arm, # Linux on arm64
|
ubuntu-22.04-arm, # Linux on arm64
|
||||||
# macos-latest, # macOS on Apple silicon
|
macos-latest, # macOS on Apple silicon
|
||||||
# macos-13, # macOS on Intel
|
macos-13, # macOS on Intel
|
||||||
# windows-latest
|
windows-latest
|
||||||
# ]
|
]
|
||||||
# set-gds-token: [false]
|
set-gds-token: [false]
|
||||||
# components: ['']
|
components: ['']
|
||||||
# include:
|
include:
|
||||||
# - java-version: 'latest-ea'
|
- java-version: 'latest-ea'
|
||||||
# distribution: 'graalvm'
|
distribution: 'graalvm'
|
||||||
# os: ubuntu-latest
|
os: ubuntu-latest
|
||||||
# - java-version: '25-ea'
|
- java-version: '25-ea'
|
||||||
# distribution: 'graalvm'
|
distribution: 'graalvm'
|
||||||
# os: ubuntu-latest
|
os: ubuntu-latest
|
||||||
# - java-version: '21'
|
- java-version: '21'
|
||||||
# distribution: ''
|
distribution: ''
|
||||||
# os: ubuntu-latest
|
os: ubuntu-latest
|
||||||
# - java-version: 'dev'
|
- java-version: 'dev'
|
||||||
# distribution: ''
|
distribution: ''
|
||||||
# os: windows-latest
|
os: windows-latest
|
||||||
# - java-version: '21'
|
- java-version: '21'
|
||||||
# distribution: 'graalvm-community'
|
distribution: 'graalvm-community'
|
||||||
# os: ubuntu-latest
|
os: ubuntu-latest
|
||||||
# components: 'native-image' # should print a warning but not fail
|
components: 'native-image' # should print a warning but not fail
|
||||||
# - java-version: '21.0.0' # test for GA version (see #63)
|
- java-version: '21.0.0' # test for GA version (see #63)
|
||||||
# distribution: 'graalvm'
|
distribution: 'graalvm'
|
||||||
# os: ubuntu-latest
|
os: ubuntu-latest
|
||||||
# - java-version: '17'
|
- java-version: '17'
|
||||||
# distribution: 'graalvm'
|
distribution: 'graalvm'
|
||||||
# os: ubuntu-latest
|
os: ubuntu-latest
|
||||||
# set-gds-token: true
|
set-gds-token: true
|
||||||
# - java-version: '17.0.13'
|
- java-version: '17.0.13'
|
||||||
# distribution: 'graalvm'
|
distribution: 'graalvm'
|
||||||
# os: ubuntu-latest
|
os: ubuntu-latest
|
||||||
# set-gds-token: true
|
set-gds-token: true
|
||||||
# steps:
|
steps:
|
||||||
# - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
||||||
# - name: Run setup-graalvm action
|
- name: Run setup-graalvm action
|
||||||
# uses: ./
|
uses: ./
|
||||||
# with:
|
with:
|
||||||
# java-version: ${{ matrix.java-version }}
|
java-version: ${{ matrix.java-version }}
|
||||||
# distribution: ${{ matrix.distribution }}
|
distribution: ${{ matrix.distribution }}
|
||||||
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
# components: ${{ matrix.components }}
|
components: ${{ matrix.components }}
|
||||||
# gds-token: ${{ matrix.set-gds-token && secrets.GDS_TOKEN || '' }}
|
gds-token: ${{ matrix.set-gds-token && secrets.GDS_TOKEN || '' }}
|
||||||
# if: ${{ env.PASSES_GDS_TOKEN_CHECK == 'true' }}
|
if: ${{ env.PASSES_GDS_TOKEN_CHECK == 'true' }}
|
||||||
# - name: Check environment
|
- name: Check environment
|
||||||
# run: |
|
run: |
|
||||||
# echo "GRAALVM_HOME: $GRAALVM_HOME"
|
echo "GRAALVM_HOME: $GRAALVM_HOME"
|
||||||
# if [[ "${{ matrix.java-version }}" == "dev" ]]; then
|
if [[ "${{ matrix.java-version }}" == "dev" ]]; then
|
||||||
# [[ "$GRAALVM_HOME" == *"$RUNNER_TEMP"* ]] || exit 12
|
[[ "$GRAALVM_HOME" == *"$RUNNER_TEMP"* ]] || exit 12
|
||||||
# else
|
else
|
||||||
# [[ "$GRAALVM_HOME" == *"$RUNNER_TOOL_CACHE"* ]] || exit 23
|
[[ "$GRAALVM_HOME" == *"$RUNNER_TOOL_CACHE"* ]] || exit 23
|
||||||
# fi
|
fi
|
||||||
# echo "JAVA_HOME: $JAVA_HOME"
|
echo "JAVA_HOME: $JAVA_HOME"
|
||||||
# java --version
|
java --version
|
||||||
# java --version | grep "GraalVM" || exit 34
|
java --version | grep "GraalVM" || exit 34
|
||||||
# native-image --version
|
native-image --version
|
||||||
# if: ${{ env.PASSES_GDS_TOKEN_CHECK == 'true' && runner.os != 'Windows' }}
|
if: ${{ env.PASSES_GDS_TOKEN_CHECK == 'true' && runner.os != 'Windows' }}
|
||||||
# - name: Check Windows environment
|
- name: Check Windows environment
|
||||||
# run: |
|
run: |
|
||||||
# echo "GRAALVM_HOME: $env:GRAALVM_HOME"
|
echo "GRAALVM_HOME: $env:GRAALVM_HOME"
|
||||||
# echo "JAVA_HOME: $env:JAVA_HOME"
|
echo "JAVA_HOME: $env:JAVA_HOME"
|
||||||
# java --version
|
java --version
|
||||||
# native-image --version
|
native-image --version
|
||||||
# if: ${{ env.PASSES_GDS_TOKEN_CHECK == 'true' && runner.os == 'Windows' }}
|
if: ${{ env.PASSES_GDS_TOKEN_CHECK == 'true' && runner.os == 'Windows' }}
|
||||||
|
|
||||||
# test-action-ce: # make sure the action works on a clean machine without building
|
test-action-ce: # make sure the action works on a clean machine without building
|
||||||
# needs: test-action
|
needs: test-action
|
||||||
# name: CE ${{ matrix.version }} + JDK${{ matrix.java-version }} on ${{ matrix.os }}
|
name: CE ${{ matrix.version }} + JDK${{ matrix.java-version }} on ${{ matrix.os }}
|
||||||
# runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
# strategy:
|
strategy:
|
||||||
# matrix:
|
matrix:
|
||||||
# version: ['latest', 'dev']
|
version: ['latest', 'dev']
|
||||||
# java-version: ['17', '20']
|
java-version: ['17', '20']
|
||||||
# components: ['native-image']
|
components: ['native-image']
|
||||||
# os: [macos-latest, windows-latest, ubuntu-latest]
|
os: [macos-latest, windows-latest, ubuntu-latest]
|
||||||
# exclude:
|
exclude:
|
||||||
# - version: 'latest'
|
- version: 'latest'
|
||||||
# java-version: '20'
|
java-version: '20'
|
||||||
# - version: 'dev'
|
- version: 'dev'
|
||||||
# java-version: '19'
|
java-version: '19'
|
||||||
# include:
|
include:
|
||||||
# - version: '22.2.0' # for update notifications
|
- version: '22.2.0' # for update notifications
|
||||||
# java-version: '17'
|
java-version: '17'
|
||||||
# components: 'native-image'
|
components: 'native-image'
|
||||||
# os: ubuntu-22.04
|
os: ubuntu-22.04
|
||||||
# - version: '21.2.0'
|
- version: '21.2.0'
|
||||||
# java-version: '8' # for JDK 8 notification
|
java-version: '8' # for JDK 8 notification
|
||||||
# components: 'native-image'
|
components: 'native-image'
|
||||||
# os: ubuntu-latest
|
os: ubuntu-latest
|
||||||
# - version: '22.3.1'
|
- version: '22.3.1'
|
||||||
# java-version: '11' # for JDK 11 notification
|
java-version: '11' # for JDK 11 notification
|
||||||
# components: 'native-image'
|
components: 'native-image'
|
||||||
# os: macos-13
|
os: macos-13
|
||||||
# - version: '22.3.1'
|
- version: '22.3.1'
|
||||||
# java-version: '17'
|
java-version: '17'
|
||||||
# components: 'native-image'
|
components: 'native-image'
|
||||||
# os: windows-2022
|
os: windows-2022
|
||||||
# - version: 'dev'
|
- version: 'dev'
|
||||||
# java-version: 'dev'
|
java-version: 'dev'
|
||||||
# components: 'native-image'
|
components: 'native-image'
|
||||||
# os: ubuntu-latest
|
os: ubuntu-latest
|
||||||
# steps:
|
steps:
|
||||||
# - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
||||||
# - name: Run setup-graalvm action
|
- name: Run setup-graalvm action
|
||||||
# uses: ./
|
uses: ./
|
||||||
# with:
|
with:
|
||||||
# version: ${{ matrix.version }}
|
version: ${{ matrix.version }}
|
||||||
# java-version: ${{ matrix.java-version }}
|
java-version: ${{ matrix.java-version }}
|
||||||
# components: ${{ matrix.components }}
|
components: ${{ matrix.components }}
|
||||||
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
# - name: Check environment
|
- name: Check environment
|
||||||
# run: |
|
run: |
|
||||||
# echo "GRAALVM_HOME: $GRAALVM_HOME"
|
echo "GRAALVM_HOME: $GRAALVM_HOME"
|
||||||
# if [[ "${{ matrix.version }}" == "dev" ]] && [[ "${{ matrix.java-version }}" == "dev" ]]; then
|
if [[ "${{ matrix.version }}" == "dev" ]] && [[ "${{ matrix.java-version }}" == "dev" ]]; then
|
||||||
# [[ "$GRAALVM_HOME" == *"$RUNNER_TEMP"* ]] || exit 12
|
[[ "$GRAALVM_HOME" == *"$RUNNER_TEMP"* ]] || exit 12
|
||||||
# else
|
else
|
||||||
# [[ "$GRAALVM_HOME" == *"$RUNNER_TOOL_CACHE"* ]] || exit 23
|
[[ "$GRAALVM_HOME" == *"$RUNNER_TOOL_CACHE"* ]] || exit 23
|
||||||
# fi
|
fi
|
||||||
# echo "JAVA_HOME: $JAVA_HOME"
|
echo "JAVA_HOME: $JAVA_HOME"
|
||||||
# java -version
|
java -version
|
||||||
# java -version 2>&1 | grep "GraalVM" || exit 34
|
java -version 2>&1 | grep "GraalVM" || exit 34
|
||||||
# native-image --version
|
native-image --version
|
||||||
# if [[ "${{ matrix.java-version }}" != "dev" ]]; then
|
if [[ "${{ matrix.java-version }}" != "dev" ]]; then
|
||||||
# gu list
|
gu list
|
||||||
# fi
|
fi
|
||||||
# if: ${{ runner.os != 'Windows' }}
|
if: ${{ runner.os != 'Windows' }}
|
||||||
# - name: Check Windows environment
|
- name: Check Windows environment
|
||||||
# run: |
|
run: |
|
||||||
# echo "GRAALVM_HOME: $env:GRAALVM_HOME"
|
echo "GRAALVM_HOME: $env:GRAALVM_HOME"
|
||||||
# echo "JAVA_HOME: $env:JAVA_HOME"
|
echo "JAVA_HOME: $env:JAVA_HOME"
|
||||||
# java -version
|
java -version
|
||||||
# native-image --version
|
native-image --version
|
||||||
# gu.cmd remove native-image
|
gu.cmd remove native-image
|
||||||
# if: ${{ runner.os == 'Windows' }}
|
if: ${{ runner.os == 'Windows' }}
|
||||||
|
|
||||||
# test-action-ee:
|
test-action-ee:
|
||||||
# needs: test-action
|
needs: test-action
|
||||||
# name: EE ${{ matrix.version }} + JDK${{ matrix.java-version }} on ${{ matrix.os }}
|
name: EE ${{ matrix.version }} + JDK${{ matrix.java-version }} on ${{ matrix.os }}
|
||||||
# if: github.event_name != 'pull_request'
|
if: github.event_name != 'pull_request'
|
||||||
# runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
# env:
|
env:
|
||||||
# # Skip builds that require a GDS token but have no access to one (e.g., secrets are unavailable in PR runs)
|
# Skip builds that require a GDS token but have no access to one (e.g., secrets are unavailable in PR runs)
|
||||||
# PASSES_GDS_TOKEN_CHECK: ${{ secrets.GDS_TOKEN != '' }}
|
PASSES_GDS_TOKEN_CHECK: ${{ secrets.GDS_TOKEN != '' }}
|
||||||
# strategy:
|
strategy:
|
||||||
# matrix:
|
matrix:
|
||||||
# version: ['latest']
|
version: ['latest']
|
||||||
# java-version: ['17']
|
java-version: ['17']
|
||||||
# components: ['native-image']
|
components: ['native-image']
|
||||||
# os: [macos-latest, windows-latest, ubuntu-latest]
|
os: [macos-latest, windows-latest, ubuntu-latest]
|
||||||
# include:
|
include:
|
||||||
# - version: '22.3.3'
|
- version: '22.3.3'
|
||||||
# java-version: '11'
|
java-version: '11'
|
||||||
# components: 'native-image'
|
components: 'native-image'
|
||||||
# os: ubuntu-latest
|
os: ubuntu-latest
|
||||||
# - version: '22.3.3'
|
- version: '22.3.3'
|
||||||
# java-version: '17'
|
java-version: '17'
|
||||||
# components: 'native-image'
|
components: 'native-image'
|
||||||
# os: ubuntu-latest
|
os: ubuntu-latest
|
||||||
# steps:
|
steps:
|
||||||
# - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
||||||
# - name: Run setup-graalvm action
|
- name: Run setup-graalvm action
|
||||||
# uses: ./
|
uses: ./
|
||||||
# with:
|
with:
|
||||||
# version: ${{ matrix.version }}
|
version: ${{ matrix.version }}
|
||||||
# gds-token: ${{ secrets.GDS_TOKEN }}
|
gds-token: ${{ secrets.GDS_TOKEN }}
|
||||||
# java-version: ${{ matrix.java-version }}
|
java-version: ${{ matrix.java-version }}
|
||||||
# components: ${{ matrix.components }}
|
components: ${{ matrix.components }}
|
||||||
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
# if: ${{ env.PASSES_GDS_TOKEN_CHECK == 'true' }}
|
if: ${{ env.PASSES_GDS_TOKEN_CHECK == 'true' }}
|
||||||
# - name: Check environment
|
- name: Check environment
|
||||||
# run: |
|
run: |
|
||||||
# echo "GRAALVM_HOME: $GRAALVM_HOME"
|
echo "GRAALVM_HOME: $GRAALVM_HOME"
|
||||||
# [[ "$GRAALVM_HOME" == *"$RUNNER_TOOL_CACHE"* ]] || exit 12
|
[[ "$GRAALVM_HOME" == *"$RUNNER_TOOL_CACHE"* ]] || exit 12
|
||||||
# echo "JAVA_HOME: $JAVA_HOME"
|
echo "JAVA_HOME: $JAVA_HOME"
|
||||||
# java --version
|
java --version
|
||||||
# java --version | grep -e "GraalVM EE" -e "Oracle GraalVM" || exit 23
|
java --version | grep -e "GraalVM EE" -e "Oracle GraalVM" || exit 23
|
||||||
# native-image --version
|
native-image --version
|
||||||
# gu list
|
gu list
|
||||||
# if: ${{ env.PASSES_GDS_TOKEN_CHECK == 'true' && runner.os != 'Windows' }}
|
if: ${{ env.PASSES_GDS_TOKEN_CHECK == 'true' && runner.os != 'Windows' }}
|
||||||
# - name: Check Windows environment
|
- name: Check Windows environment
|
||||||
# run: |
|
run: |
|
||||||
# echo "GRAALVM_HOME: $env:GRAALVM_HOME"
|
echo "GRAALVM_HOME: $env:GRAALVM_HOME"
|
||||||
# echo "JAVA_HOME: $env:JAVA_HOME"
|
echo "JAVA_HOME: $env:JAVA_HOME"
|
||||||
# java --version
|
java --version
|
||||||
# native-image --version
|
native-image --version
|
||||||
# gu.cmd remove native-image
|
gu.cmd remove native-image
|
||||||
# if: ${{ env.PASSES_GDS_TOKEN_CHECK == 'true' && runner.os == 'Windows' }}
|
if: ${{ env.PASSES_GDS_TOKEN_CHECK == 'true' && runner.os == 'Windows' }}
|
||||||
|
|
||||||
# test-action-mandrel:
|
test-action-mandrel:
|
||||||
# needs: test-action
|
needs: test-action
|
||||||
# name: ${{ matrix.version }} + JDK${{ matrix.java-version }} on ${{ matrix.os }}
|
name: ${{ matrix.version }} + JDK${{ matrix.java-version }} on ${{ matrix.os }}
|
||||||
# runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
# strategy:
|
strategy:
|
||||||
# matrix:
|
matrix:
|
||||||
# version: ['mandrel-22.2.0.0-Final', '23.0.1.2-Final', 'mandrel-latest']
|
version: ['mandrel-22.2.0.0-Final', '23.0.1.2-Final', 'mandrel-latest']
|
||||||
# java-version: ['17']
|
java-version: ['17']
|
||||||
# distribution: ['mandrel']
|
distribution: ['mandrel']
|
||||||
# os: [windows-latest, ubuntu-latest]
|
os: [windows-latest, ubuntu-latest]
|
||||||
# include:
|
include:
|
||||||
# - version: 'mandrel-latest'
|
- version: 'mandrel-latest'
|
||||||
# java-version: '17'
|
java-version: '17'
|
||||||
# distribution: '' # test empty distribution for backward compatibility
|
distribution: '' # test empty distribution for backward compatibility
|
||||||
# os: ubuntu-latest
|
os: ubuntu-latest
|
||||||
# - version: '' # test with no version
|
- version: '' # test with no version
|
||||||
# java-version: '21'
|
java-version: '21'
|
||||||
# distribution: 'mandrel'
|
distribution: 'mandrel'
|
||||||
# os: ubuntu-latest
|
os: ubuntu-latest
|
||||||
# steps:
|
steps:
|
||||||
# - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
||||||
# - name: Run setup-graalvm action
|
- name: Run setup-graalvm action
|
||||||
# uses: ./
|
uses: ./
|
||||||
# with:
|
with:
|
||||||
# version: ${{ matrix.version }}
|
version: ${{ matrix.version }}
|
||||||
# distribution: ${{ matrix.distribution }}
|
distribution: ${{ matrix.distribution }}
|
||||||
# java-version: ${{ matrix.java-version }}
|
java-version: ${{ matrix.java-version }}
|
||||||
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
# - name: Check environment
|
- name: Check environment
|
||||||
# run: |
|
run: |
|
||||||
# echo "GRAALVM_HOME: $GRAALVM_HOME"
|
echo "GRAALVM_HOME: $GRAALVM_HOME"
|
||||||
# [[ "$GRAALVM_HOME" == *"$RUNNER_TOOL_CACHE"* ]] || exit 12
|
[[ "$GRAALVM_HOME" == *"$RUNNER_TOOL_CACHE"* ]] || exit 12
|
||||||
# echo "JAVA_HOME: $JAVA_HOME"
|
echo "JAVA_HOME: $JAVA_HOME"
|
||||||
# java --version
|
java --version
|
||||||
# java --version | grep "Temurin" || exit 23
|
java --version | grep "Temurin" || exit 23
|
||||||
# native-image --version
|
native-image --version
|
||||||
# if: ${{ runner.os != 'Windows' }}
|
if: ${{ runner.os != 'Windows' }}
|
||||||
# - name: Check Windows environment
|
- name: Check Windows environment
|
||||||
# run: |
|
run: |
|
||||||
# echo "GRAALVM_HOME: $env:GRAALVM_HOME"
|
echo "GRAALVM_HOME: $env:GRAALVM_HOME"
|
||||||
# echo "JAVA_HOME: $env:JAVA_HOME"
|
echo "JAVA_HOME: $env:JAVA_HOME"
|
||||||
# java --version
|
java --version
|
||||||
# native-image --version
|
native-image --version
|
||||||
# if: ${{ runner.os == 'Windows' }}
|
if: ${{ runner.os == 'Windows' }}
|
||||||
|
|
||||||
# test-action-liberica:
|
test-action-liberica:
|
||||||
# needs: test-action
|
needs: test-action
|
||||||
# name: Liberica (${{ matrix.java-version }}, '${{ matrix.java-package }}', ${{ matrix.os }})
|
name: Liberica (${{ matrix.java-version }}, '${{ matrix.java-package }}', ${{ matrix.os }})
|
||||||
# runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
# strategy:
|
strategy:
|
||||||
# matrix:
|
matrix:
|
||||||
# java-version: ['17', '21.0.2']
|
java-version: ['17', '21.0.2']
|
||||||
# java-package: ['', 'jdk', 'jdk+fx']
|
java-package: ['', 'jdk', 'jdk+fx']
|
||||||
# os: [ubuntu-latest, macos-latest, windows-latest]
|
os: [ubuntu-latest, macos-latest, windows-latest]
|
||||||
# steps:
|
steps:
|
||||||
# - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
||||||
# - name: Run setup-graalvm action
|
- name: Run setup-graalvm action
|
||||||
# uses: ./
|
uses: ./
|
||||||
# with:
|
with:
|
||||||
# distribution: liberica
|
distribution: liberica
|
||||||
# java-version: ${{ matrix.java-version }}
|
java-version: ${{ matrix.java-version }}
|
||||||
# java-package: ${{ matrix.java-package }}
|
java-package: ${{ matrix.java-package }}
|
||||||
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
# - name: Check environment
|
- name: Check environment
|
||||||
# run: |
|
run: |
|
||||||
# echo "GRAALVM_HOME: $GRAALVM_HOME"
|
echo "GRAALVM_HOME: $GRAALVM_HOME"
|
||||||
# [[ "$GRAALVM_HOME" == *"$RUNNER_TOOL_CACHE"* ]] || exit 12
|
[[ "$GRAALVM_HOME" == *"$RUNNER_TOOL_CACHE"* ]] || exit 12
|
||||||
# echo "JAVA_HOME: $JAVA_HOME"
|
echo "JAVA_HOME: $JAVA_HOME"
|
||||||
# java --version
|
java --version
|
||||||
# java --version | fgrep -qw ${{ matrix.java-version }} || exit 23
|
java --version | fgrep -qw ${{ matrix.java-version }} || exit 23
|
||||||
# native-image --version
|
native-image --version
|
||||||
# native-image --version | fgrep -qw ${{ matrix.java-version }} || exit 24
|
native-image --version | fgrep -qw ${{ matrix.java-version }} || exit 24
|
||||||
# if: ${{ runner.os != 'Windows' }}
|
if: ${{ runner.os != 'Windows' }}
|
||||||
# - name: Check Windows environment
|
- name: Check Windows environment
|
||||||
# shell: pwsh
|
shell: pwsh
|
||||||
# run: |
|
run: |
|
||||||
# echo "GRAALVM_HOME: $env:GRAALVM_HOME"
|
echo "GRAALVM_HOME: $env:GRAALVM_HOME"
|
||||||
# echo "JAVA_HOME: $env:JAVA_HOME"
|
echo "JAVA_HOME: $env:JAVA_HOME"
|
||||||
# java --version
|
java --version
|
||||||
# if (!(java --version | findstr \<${{ matrix.java-version }}\>)) {
|
if (!(java --version | findstr \<${{ matrix.java-version }}\>)) {
|
||||||
# exit 23
|
exit 23
|
||||||
# }
|
}
|
||||||
# native-image --version
|
native-image --version
|
||||||
# if (!(native-image --version | findstr \<${{ matrix.java-version }}\>)) {
|
if (!(native-image --version | findstr \<${{ matrix.java-version }}\>)) {
|
||||||
# exit 24
|
exit 24
|
||||||
# }
|
}
|
||||||
# if: ${{ runner.os == 'Windows' }}
|
if: ${{ runner.os == 'Windows' }}
|
||||||
|
|
||||||
# test-action-native-image-windows:
|
test-action-native-image-windows:
|
||||||
# name: native-image on windows-latest
|
name: native-image on windows-latest
|
||||||
# runs-on: windows-latest
|
runs-on: windows-latest
|
||||||
# permissions:
|
|
||||||
# contents: read
|
|
||||||
# pull-requests: write # for `native-image-pr-reports` option
|
|
||||||
# steps:
|
|
||||||
# - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
|
||||||
# - name: Run setup-graalvm action
|
|
||||||
# uses: ./
|
|
||||||
# with:
|
|
||||||
# java-version: 'dev'
|
|
||||||
# distribution: 'graalvm-community'
|
|
||||||
# native-image-job-reports: 'true'
|
|
||||||
# native-image-pr-reports: 'true'
|
|
||||||
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
# - name: Build HelloWorld executable with GraalVM Native Image on Windows
|
|
||||||
# run: |
|
|
||||||
# echo 'public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } }' > HelloWorld.java
|
|
||||||
# javac HelloWorld.java
|
|
||||||
# native-image HelloWorld
|
|
||||||
# ./helloworld
|
|
||||||
|
|
||||||
# test-action-native-image-windows-msvc:
|
|
||||||
# name: native-image on windows-2022
|
|
||||||
# runs-on: windows-2022
|
|
||||||
# permissions:
|
|
||||||
# contents: read
|
|
||||||
# pull-requests: write # for `native-image-pr-reports` option
|
|
||||||
# steps:
|
|
||||||
# - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
|
||||||
# - name: Run setup-graalvm action
|
|
||||||
# uses: ./
|
|
||||||
# with:
|
|
||||||
# java-version: '17'
|
|
||||||
# distribution: 'graalvm'
|
|
||||||
# native-image-job-reports: 'true'
|
|
||||||
# native-image-pr-reports: 'true'
|
|
||||||
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
# - name: Build HelloWorld executable with GraalVM Native Image on Windows
|
|
||||||
# run: |
|
|
||||||
# echo 'public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } }' > HelloWorld.java
|
|
||||||
# javac HelloWorld.java
|
|
||||||
# native-image HelloWorld
|
|
||||||
# ./helloworld
|
|
||||||
|
|
||||||
test-action-native-image-musl-ce:
|
|
||||||
name: native-image-musl on ubuntu-latest
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
pull-requests: write # for `native-image-pr-reports` option
|
pull-requests: write # for `native-image-pr-reports` option
|
||||||
@@ -384,21 +338,19 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
java-version: 'dev'
|
java-version: 'dev'
|
||||||
distribution: 'graalvm-community'
|
distribution: 'graalvm-community'
|
||||||
native-image-musl: 'true'
|
|
||||||
native-image-job-reports: 'true'
|
native-image-job-reports: 'true'
|
||||||
native-image-pr-reports: 'true'
|
native-image-pr-reports: 'true'
|
||||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
- name: Build static HelloWorld executable with GraalVM Native Image and musl
|
- name: Build HelloWorld executable with GraalVM Native Image on Windows
|
||||||
run: |
|
run: |
|
||||||
echo 'public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } }' > HelloWorld.java
|
echo 'public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } }' > HelloWorld.java
|
||||||
javac HelloWorld.java
|
javac HelloWorld.java
|
||||||
native-image --static --libc=musl HelloWorld
|
native-image HelloWorld
|
||||||
./helloworld
|
./helloworld
|
||||||
native-image --static --libc=musl -m jdk.httpserver
|
|
||||||
./jdk.httpserver --help
|
test-action-native-image-windows-msvc:
|
||||||
test-action-native-image-musl:
|
name: native-image on windows-2022
|
||||||
name: native-image-musl on ubuntu-latest
|
runs-on: windows-2022
|
||||||
runs-on: ubuntu-latest
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
pull-requests: write # for `native-image-pr-reports` option
|
pull-requests: write # for `native-image-pr-reports` option
|
||||||
@@ -407,7 +359,34 @@ jobs:
|
|||||||
- name: Run setup-graalvm action
|
- name: Run setup-graalvm action
|
||||||
uses: ./
|
uses: ./
|
||||||
with:
|
with:
|
||||||
java-version: '25'
|
java-version: '17'
|
||||||
|
distribution: 'graalvm'
|
||||||
|
native-image-job-reports: 'true'
|
||||||
|
native-image-pr-reports: 'true'
|
||||||
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
- name: Build HelloWorld executable with GraalVM Native Image on Windows
|
||||||
|
run: |
|
||||||
|
echo 'public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } }' > HelloWorld.java
|
||||||
|
javac HelloWorld.java
|
||||||
|
native-image HelloWorld
|
||||||
|
./helloworld
|
||||||
|
|
||||||
|
test-action-native-image-musl:
|
||||||
|
name: native-image-musl + JDK${{ matrix.java-version }} on ${{ matrix.os }}
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
pull-requests: write # for `native-image-pr-reports` option
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
java-version: ['21', '25']
|
||||||
|
os: [ubuntu-latest]
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
||||||
|
- name: Run setup-graalvm action
|
||||||
|
uses: ./
|
||||||
|
with:
|
||||||
|
java-version: ${{ matrix.java-version }}
|
||||||
distribution: 'graalvm'
|
distribution: 'graalvm'
|
||||||
native-image-musl: 'true'
|
native-image-musl: 'true'
|
||||||
native-image-job-reports: 'true'
|
native-image-job-reports: 'true'
|
||||||
@@ -417,101 +396,98 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
echo 'public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } }' > HelloWorld.java
|
echo 'public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } }' > HelloWorld.java
|
||||||
javac HelloWorld.java
|
javac HelloWorld.java
|
||||||
native-image --static --libc=musl HelloWorld
|
native-image --static --libc=musl --gc=G1 HelloWorld
|
||||||
./helloworld
|
./helloworld
|
||||||
native-image --static --libc=musl --gc=G1 -m jdk.httpserver
|
|
||||||
./jdk.httpserver --help
|
|
||||||
|
|
||||||
|
test-action-extensive:
|
||||||
|
name: extensive tests on ubuntu-latest
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
pull-requests: write # for `native-image-pr-reports` option
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
||||||
|
- name: Run setup-graalvm action
|
||||||
|
uses: ./
|
||||||
|
with:
|
||||||
|
java-version: '17.0.8'
|
||||||
|
distribution: 'graalvm'
|
||||||
|
components: 'espresso,llvm-toolchain,native-image,nodejs,python,ruby,wasm'
|
||||||
|
set-java-home: 'false'
|
||||||
|
native-image-job-reports: 'true'
|
||||||
|
native-image-pr-reports: 'true'
|
||||||
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
- name: Check environment
|
||||||
|
run: |
|
||||||
|
echo "GRAALVM_HOME: $GRAALVM_HOME"
|
||||||
|
echo "JAVA_HOME: $JAVA_HOME"
|
||||||
|
[[ "$GRAALVM_HOME" != "$JAVA_HOME" ]] || exit 12
|
||||||
|
[[ $(which java) == *"graalvm"* ]] || exit 23
|
||||||
|
java --version
|
||||||
|
java -truffle --version
|
||||||
|
gu --version
|
||||||
|
gu list
|
||||||
|
[[ $(which lli) == *"graalvm"* ]] || exit 34
|
||||||
|
lli --version
|
||||||
|
native-image --version
|
||||||
|
[[ $(which node) == *"graalvm"* ]] || exit 45
|
||||||
|
node --version
|
||||||
|
graalpy --version
|
||||||
|
truffleruby --version
|
||||||
|
wasm --version
|
||||||
|
- name: Build HelloWorld.java with GraalVM Native Image
|
||||||
|
run: |
|
||||||
|
echo 'public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } }' > HelloWorld.java
|
||||||
|
javac HelloWorld.java
|
||||||
|
native-image -g HelloWorld
|
||||||
|
./helloworld
|
||||||
|
# - name: Build Ruby-FFI with TruffleRuby
|
||||||
|
# run: |
|
||||||
|
# [[ $(which bundle) == *"graalvm"* ]] || exit 57
|
||||||
|
# git clone --depth 1 https://github.com/ffi/ffi.git
|
||||||
|
# pushd ffi > /dev/null
|
||||||
|
# # https://github.com/ffi/ffi/blob/447845cb3030194c79700c86fb388a12e6f81386/.github/workflows/ci.yml#L58-L62
|
||||||
|
# bundle install
|
||||||
|
# bundle exec rake libffi
|
||||||
|
# bundle exec rake compile
|
||||||
|
# bundle exec rake test
|
||||||
|
# popd > /dev/null
|
||||||
|
- name: Remove components
|
||||||
|
run: gu remove espresso llvm-toolchain nodejs python ruby wasm
|
||||||
|
|
||||||
# test-action-extensive:
|
test-action-sbom:
|
||||||
# name: extensive tests on ubuntu-latest
|
name: test 'native-image-enable-sbom' option
|
||||||
# runs-on: ubuntu-latest
|
runs-on: ${{ matrix.os }}
|
||||||
# permissions:
|
permissions:
|
||||||
# contents: read
|
contents: write
|
||||||
# pull-requests: write # for `native-image-pr-reports` option
|
strategy:
|
||||||
# steps:
|
matrix:
|
||||||
# - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
java-version: ['25', 'latest-ea']
|
||||||
# - name: Run setup-graalvm action
|
distribution: ['graalvm']
|
||||||
# uses: ./
|
os: [macos-latest, windows-latest, ubuntu-latest, ubuntu-22.04-arm]
|
||||||
# with:
|
components: ['']
|
||||||
# java-version: '17.0.8'
|
steps:
|
||||||
# distribution: 'graalvm'
|
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
||||||
# components: 'espresso,llvm-toolchain,native-image,nodejs,python,ruby,wasm'
|
- name: Run setup-graalvm action
|
||||||
# set-java-home: 'false'
|
uses: ./
|
||||||
# native-image-job-reports: 'true'
|
with:
|
||||||
# native-image-pr-reports: 'true'
|
java-version: ${{ matrix.java-version }}
|
||||||
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
distribution: ${{ matrix.distribution }}
|
||||||
# - name: Check environment
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
# run: |
|
components: ${{ matrix.components }}
|
||||||
# echo "GRAALVM_HOME: $GRAALVM_HOME"
|
native-image-enable-sbom: 'true'
|
||||||
# echo "JAVA_HOME: $JAVA_HOME"
|
cache: 'maven'
|
||||||
# [[ "$GRAALVM_HOME" != "$JAVA_HOME" ]] || exit 12
|
- name: Build Maven project and verify that SBOM was generated and its contents
|
||||||
# [[ $(which java) == *"graalvm"* ]] || exit 23
|
run: |
|
||||||
# java --version
|
cd __tests__/sbom/main-test-app
|
||||||
# java -truffle --version
|
mvn --no-transfer-progress -Pnative package
|
||||||
# gu --version
|
bash verify-sbom.sh
|
||||||
# gu list
|
shell: bash
|
||||||
# [[ $(which lli) == *"graalvm"* ]] || exit 34
|
if: ${{ runner.os != 'Windows' }}
|
||||||
# lli --version
|
- name: Build Maven project and verify that SBOM was generated and its contents (Windows)
|
||||||
# native-image --version
|
run: |
|
||||||
# [[ $(which node) == *"graalvm"* ]] || exit 45
|
cd __tests__\sbom\main-test-app
|
||||||
# node --version
|
mvn --no-transfer-progress -Pnative package
|
||||||
# graalpy --version
|
cmd /c verify-sbom.cmd
|
||||||
# truffleruby --version
|
shell: cmd
|
||||||
# wasm --version
|
if: ${{ runner.os == 'Windows' }}
|
||||||
# - name: Build HelloWorld.java with GraalVM Native Image
|
|
||||||
# run: |
|
|
||||||
# echo 'public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } }' > HelloWorld.java
|
|
||||||
# javac HelloWorld.java
|
|
||||||
# native-image -g HelloWorld
|
|
||||||
# ./helloworld
|
|
||||||
# # - name: Build Ruby-FFI with TruffleRuby
|
|
||||||
# # run: |
|
|
||||||
# # [[ $(which bundle) == *"graalvm"* ]] || exit 57
|
|
||||||
# # git clone --depth 1 https://github.com/ffi/ffi.git
|
|
||||||
# # pushd ffi > /dev/null
|
|
||||||
# # # https://github.com/ffi/ffi/blob/447845cb3030194c79700c86fb388a12e6f81386/.github/workflows/ci.yml#L58-L62
|
|
||||||
# # bundle install
|
|
||||||
# # bundle exec rake libffi
|
|
||||||
# # bundle exec rake compile
|
|
||||||
# # bundle exec rake test
|
|
||||||
# # popd > /dev/null
|
|
||||||
# - name: Remove components
|
|
||||||
# run: gu remove espresso llvm-toolchain nodejs python ruby wasm
|
|
||||||
|
|
||||||
# test-action-sbom:
|
|
||||||
# name: test 'native-image-enable-sbom' option
|
|
||||||
# runs-on: ${{ matrix.os }}
|
|
||||||
# permissions:
|
|
||||||
# contents: write
|
|
||||||
# strategy:
|
|
||||||
# matrix:
|
|
||||||
# java-version: ['25', 'latest-ea']
|
|
||||||
# distribution: ['graalvm']
|
|
||||||
# os: [macos-latest, windows-latest, ubuntu-latest, ubuntu-22.04-arm]
|
|
||||||
# components: ['']
|
|
||||||
# steps:
|
|
||||||
# - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
|
||||||
# - name: Run setup-graalvm action
|
|
||||||
# uses: ./
|
|
||||||
# with:
|
|
||||||
# java-version: ${{ matrix.java-version }}
|
|
||||||
# distribution: ${{ matrix.distribution }}
|
|
||||||
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
# components: ${{ matrix.components }}
|
|
||||||
# native-image-enable-sbom: 'true'
|
|
||||||
# cache: 'maven'
|
|
||||||
# - name: Build Maven project and verify that SBOM was generated and its contents
|
|
||||||
# run: |
|
|
||||||
# cd __tests__/sbom/main-test-app
|
|
||||||
# mvn --no-transfer-progress -Pnative package
|
|
||||||
# bash verify-sbom.sh
|
|
||||||
# shell: bash
|
|
||||||
# if: ${{ runner.os != 'Windows' }}
|
|
||||||
# - name: Build Maven project and verify that SBOM was generated and its contents (Windows)
|
|
||||||
# run: |
|
|
||||||
# cd __tests__\sbom\main-test-app
|
|
||||||
# mvn --no-transfer-progress -Pnative package
|
|
||||||
# cmd /c verify-sbom.cmd
|
|
||||||
# shell: cmd
|
|
||||||
# if: ${{ runner.os == 'Windows' }}
|
|
||||||
|
|||||||
3838
dist/cleanup.js
generated
vendored
3838
dist/cleanup.js
generated
vendored
File diff suppressed because it is too large
Load Diff
5191
dist/main.js
generated
vendored
5191
dist/main.js
generated
vendored
File diff suppressed because it is too large
Load Diff
@@ -9,13 +9,9 @@ import _import from 'eslint-plugin-import'
|
|||||||
import jest from 'eslint-plugin-jest'
|
import jest from 'eslint-plugin-jest'
|
||||||
import prettier from 'eslint-plugin-prettier'
|
import prettier from 'eslint-plugin-prettier'
|
||||||
import globals from 'globals'
|
import globals from 'globals'
|
||||||
import path from 'node:path'
|
|
||||||
import { fileURLToPath } from 'node:url'
|
|
||||||
|
|
||||||
const __filename = fileURLToPath(import.meta.url)
|
|
||||||
const __dirname = path.dirname(__filename)
|
|
||||||
const compat = new FlatCompat({
|
const compat = new FlatCompat({
|
||||||
baseDirectory: __dirname,
|
baseDirectory: import.meta.dirname,
|
||||||
recommendedConfig: js.configs.recommended,
|
recommendedConfig: js.configs.recommended,
|
||||||
allConfig: js.configs.all
|
allConfig: js.configs.all
|
||||||
})
|
})
|
||||||
@@ -52,8 +48,18 @@ export default [
|
|||||||
sourceType: 'module',
|
sourceType: 'module',
|
||||||
|
|
||||||
parserOptions: {
|
parserOptions: {
|
||||||
project: ['tsconfig.eslint.json'],
|
projectService: {
|
||||||
tsconfigRootDir: __dirname
|
allowDefaultProject: [
|
||||||
|
'__fixtures__/*.ts',
|
||||||
|
'__tests__/*.ts',
|
||||||
|
'eslint.config.mjs',
|
||||||
|
'jest.config.js',
|
||||||
|
'rollup.cleanup.config.ts',
|
||||||
|
'rollup.main.config.ts'
|
||||||
|
],
|
||||||
|
maximumDefaultProjectFileMatchCount_THIS_WILL_SLOW_DOWN_LINTING: 32
|
||||||
|
},
|
||||||
|
tsconfigRootDir: import.meta.dirname
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@@ -61,7 +67,7 @@ export default [
|
|||||||
'import/resolver': {
|
'import/resolver': {
|
||||||
typescript: {
|
typescript: {
|
||||||
alwaysTryTypes: true,
|
alwaysTryTypes: true,
|
||||||
project: 'tsconfig.eslint.json'
|
project: 'tsconfig.json'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ export default {
|
|||||||
'^.+\\.ts$': [
|
'^.+\\.ts$': [
|
||||||
'ts-jest',
|
'ts-jest',
|
||||||
{
|
{
|
||||||
tsconfig: 'tsconfig.eslint.json',
|
tsconfig: 'tsconfig.json',
|
||||||
useESM: true
|
useESM: true
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
1242
package-lock.json
generated
1242
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
37
package.json
37
package.json
@@ -2,7 +2,7 @@
|
|||||||
"name": "setup-graalvm",
|
"name": "setup-graalvm",
|
||||||
"author": "GraalVM Community",
|
"author": "GraalVM Community",
|
||||||
"description": "GitHub Action for GraalVM",
|
"description": "GitHub Action for GraalVM",
|
||||||
"version": "1.4.0",
|
"version": "1.4.2",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"private": true,
|
"private": true,
|
||||||
"repository": {
|
"repository": {
|
||||||
@@ -37,48 +37,47 @@
|
|||||||
},
|
},
|
||||||
"license": "UPL",
|
"license": "UPL",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@actions/cache": "^4.0.5",
|
"@actions/cache": "^4.1.0",
|
||||||
"@actions/core": "^1.11.1",
|
"@actions/core": "^1.11.1",
|
||||||
"@actions/exec": "^1.1.1",
|
"@actions/exec": "^1.1.1",
|
||||||
"@actions/github": "^6.0.1",
|
"@actions/github": "^6.0.1",
|
||||||
"@actions/glob": "^0.5.0",
|
"@actions/glob": "^0.5.0",
|
||||||
"@actions/http-client": "^2.2.3",
|
"@actions/http-client": "^3.0.0",
|
||||||
"@actions/io": "^1.1.3",
|
"@actions/io": "^2.0.0",
|
||||||
"@actions/tool-cache": "^2.0.2",
|
"@actions/tool-cache": "^2.0.2",
|
||||||
"@octokit/types": "^14.1.0",
|
"@octokit/types": "^16.0.0",
|
||||||
"@github/dependency-submission-toolkit": "^2.0.5",
|
"@github/dependency-submission-toolkit": "^2.0.5",
|
||||||
"semver": "^7.7.2",
|
"semver": "^7.7.3",
|
||||||
"uuid": "^13.0.0"
|
"uuid": "^13.0.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@eslint/compat": "^1.3.2",
|
"@eslint/compat": "^1.4.1",
|
||||||
"@rollup/plugin-commonjs": "^28.0.6",
|
"@rollup/plugin-commonjs": "^29.0.0",
|
||||||
"@rollup/plugin-json": "^6.1.0",
|
"@rollup/plugin-json": "^6.1.0",
|
||||||
"@rollup/plugin-node-resolve": "^16.0.1",
|
"@rollup/plugin-node-resolve": "^16.0.3",
|
||||||
"@rollup/plugin-typescript": "^12.1.4",
|
"@rollup/plugin-typescript": "^12.3.0",
|
||||||
"@types/jest": "^30.0.0",
|
"@types/jest": "^30.0.0",
|
||||||
"@types/node": "^24.4.0",
|
"@types/node": "^24.9.2",
|
||||||
"@types/semver": "^7.7.1",
|
"@types/semver": "^7.7.1",
|
||||||
"@types/uuid": "^10.0.0",
|
"@typescript-eslint/eslint-plugin": "^8.46.2",
|
||||||
"@typescript-eslint/eslint-plugin": "^8.43.0",
|
|
||||||
"@typescript-eslint/parser": "^8.31.1",
|
"@typescript-eslint/parser": "^8.31.1",
|
||||||
"eslint": "^9.35.0",
|
"eslint": "^9.39.0",
|
||||||
"eslint-config-prettier": "^10.1.8",
|
"eslint-config-prettier": "^10.1.8",
|
||||||
"eslint-import-resolver-typescript": "^4.4.4",
|
"eslint-import-resolver-typescript": "^4.4.4",
|
||||||
"eslint-plugin-import": "^2.32.0",
|
"eslint-plugin-import": "^2.32.0",
|
||||||
"eslint-plugin-jest": "^29.0.1",
|
"eslint-plugin-jest": "^29.0.1",
|
||||||
"eslint-plugin-jsonc": "^2.20.1",
|
"eslint-plugin-jsonc": "^2.21.0",
|
||||||
"eslint-plugin-node": "^11.1.0",
|
"eslint-plugin-node": "^11.1.0",
|
||||||
"eslint-plugin-prettier": "^5.5.4",
|
"eslint-plugin-prettier": "^5.5.4",
|
||||||
"jest": "^30.1.3",
|
"jest": "^30.2.0",
|
||||||
"js-yaml": "^4.1.0",
|
"js-yaml": "^4.1.0",
|
||||||
"prettier": "^3.6.2",
|
"prettier": "^3.6.2",
|
||||||
"prettier-eslint": "^16.4.2",
|
"prettier-eslint": "^16.4.2",
|
||||||
"rollup": "^4.50.2",
|
"rollup": "^4.52.5",
|
||||||
"ts-jest": "^29.4.1",
|
"ts-jest": "^29.4.5",
|
||||||
"ts-jest-resolver": "^2.0.1",
|
"ts-jest-resolver": "^2.0.1",
|
||||||
"ts-node": "^10.9.2",
|
"ts-node": "^10.9.2",
|
||||||
"typescript": "^5.9.2"
|
"typescript": "^5.9.3"
|
||||||
},
|
},
|
||||||
"optionalDependencies": {
|
"optionalDependencies": {
|
||||||
"@rollup/rollup-linux-x64-gnu": "*"
|
"@rollup/rollup-linux-x64-gnu": "*"
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import * as otypes from '@octokit/types'
|
import * as otypes from '@octokit/types'
|
||||||
|
|
||||||
export const ACTION_VERSION = '1.4.0'
|
export const ACTION_VERSION = '1.4.2'
|
||||||
|
|
||||||
export const INPUT_VERSION = 'version'
|
export const INPUT_VERSION = 'version'
|
||||||
export const INPUT_GDS_TOKEN = 'gds-token'
|
export const INPUT_GDS_TOKEN = 'gds-token'
|
||||||
@@ -53,13 +53,13 @@ export const ERROR_REQUEST = 'Please file an issue at: https://github.com/graalv
|
|||||||
export const ERROR_HINT =
|
export const ERROR_HINT =
|
||||||
'If you think this is a mistake, please file an issue at: https://github.com/graalvm/setup-graalvm/issues.'
|
'If you think this is a mistake, please file an issue at: https://github.com/graalvm/setup-graalvm/issues.'
|
||||||
|
|
||||||
export type LatestReleaseResponse = otypes.Endpoints['GET /repos/{owner}/{repo}/releases/latest']['response']
|
export type LatestReleaseResponseData =
|
||||||
|
otypes.Endpoints['GET /repos/{owner}/{repo}/releases/latest']['response']['data']
|
||||||
|
|
||||||
export type MatchingRefsResponse = otypes.Endpoints['GET /repos/{owner}/{repo}/git/matching-refs/{ref}']['response']
|
export type MatchingRefsResponseData =
|
||||||
|
otypes.Endpoints['GET /repos/{owner}/{repo}/git/matching-refs/{ref}']['response']['data']
|
||||||
|
|
||||||
export type ReleasesResponse = otypes.Endpoints['GET /repos/{owner}/{repo}/releases']['response']
|
export type ContentsResponseData = otypes.Endpoints['GET /repos/{owner}/{repo}/contents/{path}']['response']['data']
|
||||||
|
|
||||||
export type ContentsResponse = otypes.Endpoints['GET /repos/{owner}/{repo}/contents/{path}']['response']
|
|
||||||
|
|
||||||
export interface OracleGraalVMEAFile {
|
export interface OracleGraalVMEAFile {
|
||||||
filename: string
|
filename: string
|
||||||
|
|||||||
@@ -2,9 +2,10 @@ import * as c from '../constants.js'
|
|||||||
import * as core from '@actions/core'
|
import * as core from '@actions/core'
|
||||||
import * as tc from '@actions/tool-cache'
|
import * as tc from '@actions/tool-cache'
|
||||||
import { join } from 'path'
|
import { join } from 'path'
|
||||||
|
import { downloadFile } from '../utils.js'
|
||||||
|
|
||||||
const MUSL_VERSION = '1.2.5.1'
|
|
||||||
const MUSL_NAME = 'musl-toolchain'
|
const MUSL_NAME = 'musl-toolchain'
|
||||||
|
const MUSL_VERSION = '1.2.5-oracle-00001'
|
||||||
|
|
||||||
export async function setUpNativeImageMusl(): Promise<void> {
|
export async function setUpNativeImageMusl(): Promise<void> {
|
||||||
if (!c.IS_LINUX) {
|
if (!c.IS_LINUX) {
|
||||||
@@ -16,8 +17,8 @@ export async function setUpNativeImageMusl(): Promise<void> {
|
|||||||
core.info(`Found ${MUSL_NAME} ${MUSL_VERSION} in tool-cache @ ${toolPath}`)
|
core.info(`Found ${MUSL_NAME} ${MUSL_VERSION} in tool-cache @ ${toolPath}`)
|
||||||
} else {
|
} else {
|
||||||
core.startGroup(`Setting up musl for GraalVM Native Image...`)
|
core.startGroup(`Setting up musl for GraalVM Native Image...`)
|
||||||
const muslDownloadPath = await tc.downloadTool(
|
const muslDownloadPath = await downloadFile(
|
||||||
`https://github.com/graalvm/setup-graalvm/releases/download/v1.3.7/musl-toolchain-amd64-1.2.5-gcc10.3.0-zlib1.2.13.tar.gz`
|
`https://gds.oracle.com/download/bfs/archive/musl-toolchain-${MUSL_VERSION}-linux-amd64.tar.gz`
|
||||||
)
|
)
|
||||||
const muslExtractPath = await tc.extractTar(muslDownloadPath)
|
const muslExtractPath = await tc.extractTar(muslDownloadPath)
|
||||||
const muslPath = join(muslExtractPath, MUSL_NAME)
|
const muslPath = join(muslExtractPath, MUSL_NAME)
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ import * as c from './constants.js'
|
|||||||
import * as core from '@actions/core'
|
import * as core from '@actions/core'
|
||||||
import * as semver from 'semver'
|
import * as semver from 'semver'
|
||||||
import {
|
import {
|
||||||
|
downloadFile,
|
||||||
downloadAndExtractJDK,
|
downloadAndExtractJDK,
|
||||||
downloadExtractAndCacheJDK,
|
downloadExtractAndCacheJDK,
|
||||||
getContents,
|
getContents,
|
||||||
@@ -10,7 +11,6 @@ import {
|
|||||||
getTaggedRelease
|
getTaggedRelease
|
||||||
} from './utils.js'
|
} from './utils.js'
|
||||||
import { downloadGraalVM, downloadGraalVMEELegacy } from './gds.js'
|
import { downloadGraalVM, downloadGraalVMEELegacy } from './gds.js'
|
||||||
import { downloadTool } from '@actions/tool-cache'
|
|
||||||
import { basename } from 'path'
|
import { basename } from 'path'
|
||||||
|
|
||||||
const GRAALVM_DL_BASE = 'https://download.oracle.com/graalvm'
|
const GRAALVM_DL_BASE = 'https://download.oracle.com/graalvm'
|
||||||
@@ -153,7 +153,7 @@ function determineToolName(javaVersion: string, isCommunity: boolean) {
|
|||||||
|
|
||||||
async function downloadGraalVMJDK(downloadUrl: string, javaVersion: string): Promise<string> {
|
async function downloadGraalVMJDK(downloadUrl: string, javaVersion: string): Promise<string> {
|
||||||
try {
|
try {
|
||||||
return await downloadTool(downloadUrl)
|
return await downloadFile(downloadUrl)
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
if (error instanceof Error && error.message.includes('404')) {
|
if (error instanceof Error && error.message.includes('404')) {
|
||||||
// Not Found
|
// Not Found
|
||||||
@@ -174,7 +174,7 @@ export async function setUpGraalVMJDKDevBuild(): Promise<string> {
|
|||||||
return downloadAndExtractJDK(downloadUrl)
|
return downloadAndExtractJDK(downloadUrl)
|
||||||
}
|
}
|
||||||
|
|
||||||
export function findHighestJavaVersion(release: c.LatestReleaseResponse['data'], version: string): string {
|
export function findHighestJavaVersion(release: c.LatestReleaseResponseData, version: string): string {
|
||||||
const graalVMIdentifierPattern = determineGraalVMLegacyIdentifier(false, version, '(\\d+)')
|
const graalVMIdentifierPattern = determineGraalVMLegacyIdentifier(false, version, '(\\d+)')
|
||||||
const expectedFileNameRegExp = new RegExp(
|
const expectedFileNameRegExp = new RegExp(
|
||||||
`^${graalVMIdentifierPattern}${c.GRAALVM_FILE_EXTENSION.replace(/\./g, '\\.')}$`
|
`^${graalVMIdentifierPattern}${c.GRAALVM_FILE_EXTENSION.replace(/\./g, '\\.')}$`
|
||||||
@@ -214,7 +214,7 @@ export async function setUpGraalVMLatest_22_X(gdsToken: string, javaVersion: str
|
|||||||
return setUpGraalVMRelease(gdsToken, version, javaVersion)
|
return setUpGraalVMRelease(gdsToken, version, javaVersion)
|
||||||
}
|
}
|
||||||
|
|
||||||
export function findGraalVMVersion(release: c.LatestReleaseResponse['data']) {
|
export function findGraalVMVersion(release: c.LatestReleaseResponseData) {
|
||||||
const tag_name = release.tag_name
|
const tag_name = release.tag_name
|
||||||
if (!tag_name.startsWith(GRAALVM_TAG_PREFIX)) {
|
if (!tag_name.startsWith(GRAALVM_TAG_PREFIX)) {
|
||||||
throw new Error(`Could not find latest GraalVM release: ${tag_name}`)
|
throw new Error(`Could not find latest GraalVM release: ${tag_name}`)
|
||||||
@@ -234,7 +234,7 @@ export async function setUpGraalVMRelease(gdsToken: string, version: string, jav
|
|||||||
return downloadExtractAndCacheJDK(downloader, toolName, version)
|
return downloadExtractAndCacheJDK(downloader, toolName, version)
|
||||||
}
|
}
|
||||||
|
|
||||||
function findDownloadUrl(release: c.LatestReleaseResponse['data'], javaVersion: string): string {
|
function findDownloadUrl(release: c.LatestReleaseResponseData, javaVersion: string): string {
|
||||||
const graalVMIdentifier = determineGraalVMLegacyIdentifier(false, c.VERSION_DEV, javaVersion)
|
const graalVMIdentifier = determineGraalVMLegacyIdentifier(false, c.VERSION_DEV, javaVersion)
|
||||||
const expectedFileName = `${graalVMIdentifier}${c.GRAALVM_FILE_EXTENSION}`
|
const expectedFileName = `${graalVMIdentifier}${c.GRAALVM_FILE_EXTENSION}`
|
||||||
for (const asset of release.assets) {
|
for (const asset of release.assets) {
|
||||||
@@ -260,7 +260,7 @@ async function downloadGraalVMCELegacy(version: string, javaVersion: string): Pr
|
|||||||
const graalVMIdentifier = determineGraalVMLegacyIdentifier(false, version, javaVersion)
|
const graalVMIdentifier = determineGraalVMLegacyIdentifier(false, version, javaVersion)
|
||||||
const downloadUrl = `${GRAALVM_CE_DL_BASE}/${GRAALVM_TAG_PREFIX}${version}/${graalVMIdentifier}${c.GRAALVM_FILE_EXTENSION}`
|
const downloadUrl = `${GRAALVM_CE_DL_BASE}/${GRAALVM_TAG_PREFIX}${version}/${graalVMIdentifier}${c.GRAALVM_FILE_EXTENSION}`
|
||||||
try {
|
try {
|
||||||
return await downloadTool(downloadUrl)
|
return await downloadFile(downloadUrl)
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
if (error instanceof Error && error.message.includes('404')) {
|
if (error instanceof Error && error.message.includes('404')) {
|
||||||
// Not Found
|
// Not Found
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
import * as c from './constants.js'
|
import * as c from './constants.js'
|
||||||
import * as semver from 'semver'
|
import * as semver from 'semver'
|
||||||
import { downloadExtractAndCacheJDK, getTaggedRelease, getMatchingTags } from './utils.js'
|
import { downloadFile, downloadExtractAndCacheJDK, getTaggedRelease, getMatchingTags } from './utils.js'
|
||||||
import { downloadTool } from '@actions/tool-cache'
|
|
||||||
import { spawnSync } from 'child_process'
|
import { spawnSync } from 'child_process'
|
||||||
|
|
||||||
const LIBERICA_GH_USER = 'bell-sw'
|
const LIBERICA_GH_USER = 'bell-sw'
|
||||||
@@ -13,7 +12,7 @@ export async function setUpLiberica(javaVersion: string, javaPackage: string): P
|
|||||||
const resolvedJavaVersion = await findLatestLibericaJavaVersion(javaVersion)
|
const resolvedJavaVersion = await findLatestLibericaJavaVersion(javaVersion)
|
||||||
const downloadUrl = await findLibericaURL(resolvedJavaVersion, javaPackage)
|
const downloadUrl = await findLibericaURL(resolvedJavaVersion, javaPackage)
|
||||||
const toolName = determineToolName(javaVersion, javaPackage)
|
const toolName = determineToolName(javaVersion, javaPackage)
|
||||||
return downloadExtractAndCacheJDK(async () => downloadTool(downloadUrl), toolName, javaVersion)
|
return downloadExtractAndCacheJDK(async () => downloadFile(downloadUrl), toolName, javaVersion)
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function findLatestLibericaJavaVersion(javaVersion: string): Promise<string> {
|
export async function findLatestLibericaJavaVersion(javaVersion: string): Promise<string> {
|
||||||
|
|||||||
30
src/utils.ts
30
src/utils.ts
@@ -5,9 +5,10 @@ import * as semver from 'semver'
|
|||||||
import * as tc from '@actions/tool-cache'
|
import * as tc from '@actions/tool-cache'
|
||||||
import * as fs from 'fs'
|
import * as fs from 'fs'
|
||||||
import { ExecOptions, exec as e } from '@actions/exec'
|
import { ExecOptions, exec as e } from '@actions/exec'
|
||||||
|
import { ok } from 'assert'
|
||||||
import { readFileSync, readdirSync } from 'fs'
|
import { readFileSync, readdirSync } from 'fs'
|
||||||
import { createHash } from 'crypto'
|
import { createHash } from 'crypto'
|
||||||
import { join } from 'path'
|
import { extname, join } from 'path'
|
||||||
import { tmpdir } from 'os'
|
import { tmpdir } from 'os'
|
||||||
import { GitHub } from '@actions/github/lib/utils.js'
|
import { GitHub } from '@actions/github/lib/utils.js'
|
||||||
|
|
||||||
@@ -18,17 +19,17 @@ export async function exec(commandLine: string, args?: string[], options?: ExecO
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function getLatestRelease(repo: string): Promise<c.LatestReleaseResponse['data']> {
|
export async function getLatestRelease(repo: string): Promise<c.LatestReleaseResponseData> {
|
||||||
const octokit = getOctokit()
|
const octokit = getOctokit()
|
||||||
return (
|
return (
|
||||||
await octokit.request('GET /repos/{owner}/{repo}/releases/latest', {
|
await octokit.request('GET /repos/{owner}/{repo}/releases/latest', {
|
||||||
owner: c.GRAALVM_GH_USER,
|
owner: c.GRAALVM_GH_USER,
|
||||||
repo
|
repo
|
||||||
})
|
})
|
||||||
).data
|
).data as c.LatestReleaseResponseData /** missing digest property */
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function getContents(repo: string, path: string): Promise<c.ContentsResponse['data']> {
|
export async function getContents(repo: string, path: string): Promise<c.ContentsResponseData> {
|
||||||
const octokit = getOctokit()
|
const octokit = getOctokit()
|
||||||
return (
|
return (
|
||||||
await octokit.request('GET /repos/{owner}/{repo}/contents/{path}', {
|
await octokit.request('GET /repos/{owner}/{repo}/contents/{path}', {
|
||||||
@@ -39,11 +40,7 @@ export async function getContents(repo: string, path: string): Promise<c.Content
|
|||||||
).data
|
).data
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function getTaggedRelease(
|
export async function getTaggedRelease(owner: string, repo: string, tag: string): Promise<c.LatestReleaseResponseData> {
|
||||||
owner: string,
|
|
||||||
repo: string,
|
|
||||||
tag: string
|
|
||||||
): Promise<c.LatestReleaseResponse['data']> {
|
|
||||||
const octokit = getOctokit()
|
const octokit = getOctokit()
|
||||||
return (
|
return (
|
||||||
await octokit.request('GET /repos/{owner}/{repo}/releases/tags/{tag}', {
|
await octokit.request('GET /repos/{owner}/{repo}/releases/tags/{tag}', {
|
||||||
@@ -51,14 +48,14 @@ export async function getTaggedRelease(
|
|||||||
repo,
|
repo,
|
||||||
tag
|
tag
|
||||||
})
|
})
|
||||||
).data
|
).data as c.LatestReleaseResponseData /** missing digest property */
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function getMatchingTags(
|
export async function getMatchingTags(
|
||||||
owner: string,
|
owner: string,
|
||||||
repo: string,
|
repo: string,
|
||||||
tagPrefix: string
|
tagPrefix: string
|
||||||
): Promise<c.MatchingRefsResponse['data']> {
|
): Promise<c.MatchingRefsResponseData> {
|
||||||
const octokit = getOctokit()
|
const octokit = getOctokit()
|
||||||
return (
|
return (
|
||||||
await octokit.request('GET /repos/{owner}/{repo}/git/matching-refs/tags/{tagPrefix}', {
|
await octokit.request('GET /repos/{owner}/{repo}/git/matching-refs/tags/{tagPrefix}', {
|
||||||
@@ -90,6 +87,17 @@ export async function downloadExtractAndCacheJDK(
|
|||||||
return findJavaHomeInSubfolder(toolPath)
|
return findJavaHomeInSubfolder(toolPath)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export async function downloadFile(downloadUrl: string): Promise<string> {
|
||||||
|
const dest = join(_getTempDirectory(), crypto.randomUUID(), extname(downloadUrl))
|
||||||
|
return tc.downloadTool(downloadUrl, dest)
|
||||||
|
}
|
||||||
|
|
||||||
|
function _getTempDirectory(): string {
|
||||||
|
const tempDirectory = process.env['RUNNER_TEMP'] || ''
|
||||||
|
ok(tempDirectory, 'Expected RUNNER_TEMP to be defined')
|
||||||
|
return tempDirectory
|
||||||
|
}
|
||||||
|
|
||||||
export function calculateSHA256(filePath: string): string {
|
export function calculateSHA256(filePath: string): string {
|
||||||
const hashSum = createHash('sha256')
|
const hashSum = createHash('sha256')
|
||||||
hashSum.update(readFileSync(filePath))
|
hashSum.update(readFileSync(filePath))
|
||||||
|
|||||||
@@ -1,23 +0,0 @@
|
|||||||
{
|
|
||||||
"$schema": "https://json.schemastore.org/tsconfig",
|
|
||||||
"compilerOptions": {
|
|
||||||
"allowSyntheticDefaultImports": true,
|
|
||||||
"declaration": false,
|
|
||||||
"declarationMap": false,
|
|
||||||
"esModuleInterop": true,
|
|
||||||
"forceConsistentCasingInFileNames": true,
|
|
||||||
"lib": ["ES2022"],
|
|
||||||
"module": "NodeNext",
|
|
||||||
"moduleResolution": "NodeNext",
|
|
||||||
"newLine": "lf",
|
|
||||||
"noImplicitAny": true,
|
|
||||||
"noUnusedLocals": true,
|
|
||||||
"noUnusedParameters": false,
|
|
||||||
"pretty": true,
|
|
||||||
"resolveJsonModule": true,
|
|
||||||
"sourceMap": false,
|
|
||||||
"strict": true,
|
|
||||||
"strictNullChecks": true,
|
|
||||||
"target": "ES2022"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,18 +0,0 @@
|
|||||||
{
|
|
||||||
"$schema": "https://json.schemastore.org/tsconfig",
|
|
||||||
"extends": "./tsconfig.base.json",
|
|
||||||
"compilerOptions": {
|
|
||||||
"allowJs": true,
|
|
||||||
"noEmit": true
|
|
||||||
},
|
|
||||||
"exclude": ["dist", "node_modules"],
|
|
||||||
"include": [
|
|
||||||
"__fixtures__",
|
|
||||||
"__tests__",
|
|
||||||
"src",
|
|
||||||
"eslint.config.mjs",
|
|
||||||
"jest.config.js",
|
|
||||||
"rollup.cleanup.config.ts",
|
|
||||||
"rollup.main.config.ts"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,11 +1,25 @@
|
|||||||
{
|
{
|
||||||
"$schema": "https://json.schemastore.org/tsconfig",
|
"$schema": "https://json.schemastore.org/tsconfig",
|
||||||
"extends": "./tsconfig.base.json",
|
|
||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
|
"allowSyntheticDefaultImports": true,
|
||||||
|
"declaration": false,
|
||||||
|
"declarationMap": false,
|
||||||
|
"esModuleInterop": true,
|
||||||
|
"forceConsistentCasingInFileNames": true,
|
||||||
"isolatedModules": true,
|
"isolatedModules": true,
|
||||||
|
"lib": ["ES2022"],
|
||||||
"module": "NodeNext",
|
"module": "NodeNext",
|
||||||
"moduleResolution": "NodeNext",
|
"moduleResolution": "NodeNext",
|
||||||
"outDir": "./dist"
|
"newLine": "lf",
|
||||||
|
"noImplicitAny": true,
|
||||||
|
"noUnusedLocals": true,
|
||||||
|
"noUnusedParameters": false,
|
||||||
|
"outDir": "./dist",
|
||||||
|
"pretty": true,
|
||||||
|
"resolveJsonModule": true,
|
||||||
|
"strict": true,
|
||||||
|
"strictNullChecks": true,
|
||||||
|
"target": "ES2022"
|
||||||
},
|
},
|
||||||
"exclude": ["__fixtures__", "__tests__", "coverage", "dist", "node_modules"],
|
"exclude": ["__fixtures__", "__tests__", "coverage", "dist", "node_modules"],
|
||||||
"include": ["src"]
|
"include": ["src"]
|
||||||
|
|||||||
Reference in New Issue
Block a user