From 07ea605e4b1f0f8b0621155fb1722d6094c3e183 Mon Sep 17 00:00:00 2001 From: Gregory Mitchell <54124162+gmitch215@users.noreply.github.com> Date: Wed, 5 Jun 2024 16:00:38 -0500 Subject: [PATCH] Add Docs + Distro Factory --- docs/advanced-usage.md | 14 ++++++++++++++ src/distributions/distribution-factory.ts | 3 ++- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/docs/advanced-usage.md b/docs/advanced-usage.md index 3503748..0241178 100644 --- a/docs/advanced-usage.md +++ b/docs/advanced-usage.md @@ -8,6 +8,7 @@ - [Amazon Corretto](#Amazon-Corretto) - [Oracle](#Oracle) - [Alibaba Dragonwell](#Alibaba-Dragonwell) + - [JetBrains](#JetBrains) - [Installing custom Java package type](#Installing-custom-Java-package-type) - [Installing custom Java architecture](#Installing-custom-Java-architecture) - [Installing custom Java distribution from local file](#Installing-Java-from-local-file) @@ -142,6 +143,19 @@ steps: - run: java -cp java HelloWorldApp ``` +### JetBrains +**NOTE:** JetBrains only provides jdk and is only available for LTS versions 11 or later. + +```yaml +steps: +- uses: actions/checkout@v4 +- uses: actions/setup-java@v4 + with: + distribution: 'jetbrains' + java-version: '11' +- run: java -cp java HelloWorldApp +``` + ## Installing custom Java package type ```yaml steps: diff --git a/src/distributions/distribution-factory.ts b/src/distributions/distribution-factory.ts index 52a41b5..94c8b72 100644 --- a/src/distributions/distribution-factory.ts +++ b/src/distributions/distribution-factory.ts @@ -23,7 +23,8 @@ enum JavaDistribution { Semeru = 'semeru', Corretto = 'corretto', Oracle = 'oracle', - Dragonwell = 'dragonwell' + Dragonwell = 'dragonwell', + JetBrains = 'jetbrains', } export function getJavaDistribution(