update yazi's themes
This commit is contained in:
@@ -13,7 +13,7 @@ targetTypes=("os" "session" "status")
|
||||
if ! python3 - "$file" "$colorHex" "${targetTypes[@]}"; then {
|
||||
log_error "Failed to edit ${file}"
|
||||
exit 1
|
||||
}; fi <<EOF
|
||||
}; fi << EOF
|
||||
import json
|
||||
import sys
|
||||
|
||||
@@ -55,10 +55,5 @@ if data is not None:
|
||||
json.dump(data, f, indent=4)
|
||||
EOF
|
||||
|
||||
if [ $? -ne 0 ]; then
|
||||
log_error "Failed to edit ${file}"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
log_success "oh-my-posh"
|
||||
|
||||
|
||||
@@ -8,12 +8,10 @@
|
||||
|
||||
file="$path"/../starship.toml
|
||||
|
||||
sed -i \
|
||||
if ! sed -i \
|
||||
-e "s/^palette\s*=.*/palette = '${palette}'/" \
|
||||
-e "/^\[palettes\.${palette}\]/,/^\[/{s/^accent\s*=.*/accent = \"#${colorHex}\"/}" \
|
||||
"$file"
|
||||
|
||||
if [ $? -ne 0 ]; then
|
||||
"$file"; then
|
||||
log_error "Failed to edit ${file}"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
@@ -10,5 +10,9 @@ end
|
||||
if test -f $HOME/.config/posh_theme.omp.json; and type -q oh-my-posh
|
||||
eval (oh-my-posh init fish --config $HOME/.config/posh_theme.omp.json)
|
||||
else if type -q starship
|
||||
function starship_transient_prompt_func
|
||||
starship module character
|
||||
end
|
||||
eval (starship init fish)
|
||||
enable_transience
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user