Skip to content

Setup Sdkman

Actions
Manage dependencies with sdkman
v1
Latest
Star (1)

Test Test-self-hosted

Setup Sdkman Action

A simple Github action, that makes Sdkman's managed SDKs available for your GitHub actions workflow.

Installed dependencies are cached via actions/cache, however, it is used for gihub-hosted runner only, because for a self-hosted runner it works pretty slow.

Usage

on: [pull_request]

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout Repo
        uses: actions/checkout@v2
      - name: setup kscript
        uses: sfesenko/setup-sdkman@v1
        with:
          deps: kscript
      - name: run kscript
        run: kscript 'println("Hello, world!")'

Dependeny version also may be specified:

      - name: Install GrallVM
        uses: sfesenko/setup-sdkman@v1
        with:
          deps: java:21.3.0.r17-grl

All installed sdks will be added to $PATH automatically, but in order to make sdk command available, sdkman's init script must be referenced explicitly:

jobs:
  my-job:
    runs-on: ubuntu-latest
    steps:
      - uses: sfesenko/setup-sdkman@v1
      - run: |
          source ~/.sdkman/bin/sdkman-init.sh
          sdk version

Setup Sdkman is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.

About

Manage dependencies with sdkman
v1
Latest

Setup Sdkman is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.