Skip to content

spaceship-prompt/spaceship-gradle

Repository files navigation

⬡ + 🚀
Spaceship Gradle

Gradle section for Spaceship prompt

GitHub Release GitHub Workflow Status Spaceship Twitter Chat on Discord

Current Gradle version, through gradle or gradlew ().

Installing

You need to source this plugin somewhere in your dotfiles. Here's how to do it with some popular tools:

Execute this command to clone this repo into Oh-My-Zsh plugin's folder:

git clone https://github.com/spaceship-prompt/spaceship-gradle.git $ZSH_CUSTOM/plugins/spaceship-gradle

Include spaceship-gradle in Oh-My-Zsh plugins list:

plugins=($plugins spaceship-gradle)
zplug "spaceship-prompt/spaceship-gradle"
antigen bundle "spaceship-prompt/spaceship-gradle"
antibody bundle "spaceship-prompt/spaceship-gradle"
zinit light "spaceship-prompt/spaceship-gradle"
zgen load "spaceship-prompt/spaceship-gradle"
[plugins.spaceship-gradle]
github = "spaceship-prompt/spaceship-gradle"

Usage

After installing, add the following line to your .zshrc in order to include Ember section in the prompt:

spaceship add gradle

Options

Shows current Gradle version using gradle or gradlew only within folder containing settings.gradle and settings.gradle.kts files.

Variable Default Meaning
SPACESHIP_GRADLE_SHOW true Current Gradle section
SPACESHIP_GRADLE_PREFIX $SPACESHIP_PROMPT_DEFAULT_PREFIX Prefix before Gradle section
SPACESHIP_GRADLE_SUFFIX $SPACESHIP_PROMPT_DEFAULT_SUFFIX Suffix after Gradle section
SPACESHIP_GRADLE_SYMBOL ⬡· Character to be shown before Gradle section
SPACESHIP_GRADLE_DEFAULT_VERSION Gradle version to be treated as default
SPACESHIP_GRADLE_COLOR green Color of Gradle section

License

MIT © Denys Dovhan and Sergey Shatunov