Skip to content

Commit 64c3be9

Browse files
tbhaxorTobias Heinlein
authored andcommitted
Fix lint errors in multiple files (Bash-it#2192)
* fix (plugins): enable interpretation of backslash escapes in colors * fix (lint): disable SC2317 in install.sh * fix (lint): SC2086 in agnoster theme * fix (lint): remove exit from install.sh as it is already implemented in the calling function
1 parent a81fa84 commit 64c3be9

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

install.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ function _bash-it_show_usage() {
1212
echo "--no-modify-config (-n): Do not modify existing config file"
1313
echo "--append-to-config (-a): Keep existing config file and append bash-it templates at the end"
1414
echo "--overwrite-backup (-f): Overwrite existing backup"
15-
exit 0
1615
}
1716

1817
# enable a thing

plugins/available/colors.plugin.bash

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@ function __() {
88
function __make_ansi() {
99
next=$1
1010
shift
11-
echo "\[\e[$("__$next" "$@")m\]"
11+
echo -e "\[\e[$("__$next" "$@")m\]"
1212
}
1313

1414
function __make_echo() {
1515
next=$1
1616
shift
17-
echo "\033[$("__$next" "$@")m"
17+
echo -e "\033[$("__$next" "$@")m"
1818
}
1919

2020
function __reset() {

themes/agnoster/agnoster.theme.bash

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ prompt_segment() {
182182
# declare -p codes
183183

184184
if [[ $CURRENT_BG != NONE && $1 != "$CURRENT_BG" ]]; then
185-
declare -a intermediate=("$(fg_color $CURRENT_BG)" "$(bg_color "$1")")
185+
declare -a intermediate=("$(fg_color "$CURRENT_BG")" "$(bg_color "$1")")
186186
debug "pre prompt " "$(ansi intermediate[@])"
187187
PR="$PR $(ansi intermediate[@])$SEGMENT_SEPARATOR"
188188
debug "post prompt " "$(ansi codes[@])"

0 commit comments

Comments
 (0)