Installing the Graal Development Kit for Micronaut Command Line Interface

The Graal Development Kit for Micronaut (GDK) Command Line Interface (CLI) is an optional but convenient way to create applications. The best way to install the GDK CLI on Unix systems is with SDKMAN! which greatly simplifies installing and managing multiple versions of the CLI.

Install with SDKMAN! #

Linux and macOS users can install the GDK CLI using SDKMAN!. Before installing, check if you have latest version of SDKMAN! installed. If not, run:

sdk update

To install the GDK CLI, install the gcn SDKMAN! candidate:

sdk install gcn

To see the available versions, run:

sdk list gcn

You can also specify the version to the sdk install command, for example:

sdk install gcn 5.0.2

For more information about using SDKMAN!, see SDKMAN! Usage.

Note: The SDKMAN! candidate is named gcn. It installs the GDK CLI, which is available as the gdk command.

You should now be able to run the GDK CLI:

gdk
| Starting interactive mode...
| Enter a command name to run. Use TAB for completion:
gdk>

Find all available commands by entering --help. Enter exit to leave the shell.

Install with Homebrew (macOS) #

Setup the tap for the cask:

brew tap oracle/gdk https://github.com/oracle/graal-dev-kit
brew trust oracle/gdk

Then install the GDK CLI tool:

brew install oracle/gdk/gdk-<version>

For example:

brew install oracle/gdk/gdk-5.0

For more information about using Homebrew, visit their homepage.

If macOS displays a message that Apple could not verify gdk, open System Settings, go to Privacy & Security, and click Open Anyway for gdk.

Alternatively, remove the quarantine attribute from the installed command:

xattr -dr com.apple.quarantine "$(which gdk)"

You should now be able to run the GDK CLI:

gdk
| Starting interactive mode...
| Enter a command name to run. Use TAB for completion:
gdk>

Find all available commands by entering --help. Enter exit to leave the shell.

Other Platforms #

For other platforms, download the tool from GitHub releases.

Learn More #