Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: proposal for a way to configure dimmer colors #600

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/main/bash/sdkman-init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ unset f
if [ -f "${SDKMAN_DIR}/etc/config" ]; then
source "${SDKMAN_DIR}/etc/config"
fi
[[ "$sdkman_colour_style" == "dark" ]] && sdkman_colour_style_code=2 || sdkman_colour_style_code=1

# Create upgrade delay file if it doesn't exist
if [[ ! -f "${SDKMAN_DIR}/var/delay_upgrade" ]]; then
Expand Down
1 change: 1 addition & 0 deletions src/main/bash/sdkman-main.sh
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ function sdk {
if [ -f "${SDKMAN_DIR}/etc/config" ]; then
source "${SDKMAN_DIR}/etc/config"
fi
[[ "$sdkman_colour_style" == "dark" ]] && sdkman_colour_style_code=2 || sdkman_colour_style_code=1

# no command provided
if [[ -z "$COMMAND" ]]; then
Expand Down
4 changes: 2 additions & 2 deletions src/main/bash/sdkman-utils.sh
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ function __sdkman_echo {
if [[ "$sdkman_colour_enable" == 'false' ]]; then
echo -e "$2"
else
echo -e "\033[1;$1$2\033[0m"
echo -e "\033[$sdkman_colour_style_code;$1$2\033[0m"
fi
}

Expand Down Expand Up @@ -100,6 +100,6 @@ function __sdkman_echo_confirm {
if [[ "$sdkman_colour_enable" == 'false' ]]; then
echo -n "$1"
else
echo -e -n "\033[1;33m$1\033[0m"
echo -e -n "\033[$sdkman_colour_style_code;33m$1\033[0m"
fi
}