mirror of
https://github.com/romkatv/powerlevel10k.git
synced 2024-11-11 00:00:06 +00:00
Added a default value for DIR_SHOW_WRITABLE.
Variable POWERLEVEL9K_DIR_SHOW_WRITABLE is now default set to false.
This commit is contained in:
parent
b567ab22c2
commit
c4a1d91118
1 changed files with 2 additions and 1 deletions
|
@ -689,6 +689,7 @@ prompt_command_execution_time() {
|
|||
# Dir: current working directory
|
||||
set_default POWERLEVEL9K_DIR_PATH_SEPARATOR "/"
|
||||
set_default POWERLEVEL9K_HOME_FOLDER_ABBREVIATION "~"
|
||||
set_default POWERLEVEL9K_DIR_SHOW_WRITABLE false
|
||||
prompt_dir() {
|
||||
local current_path="$(print -P "%~")"
|
||||
if [[ -n "$POWERLEVEL9K_SHORTEN_DIR_LENGTH" || "$POWERLEVEL9K_SHORTEN_STRATEGY" == "truncate_with_folder_marker" ]]; then
|
||||
|
@ -805,7 +806,7 @@ prompt_dir() {
|
|||
"NOT_WRITABLE" "LOCK_ICON"
|
||||
)
|
||||
local current_state="DEFAULT"
|
||||
if [[ "${POWERLEVEL9K_DIR_SHOW_WRITABLE}" == "true" && ! -w "$PWD" ]]; then
|
||||
if [[ "${POWERLEVEL9K_DIR_SHOW_WRITABLE}" == true && ! -w "$PWD" ]]; then
|
||||
current_state="NOT_WRITABLE"
|
||||
elif [[ $(print -P "%~") == '~' ]]; then
|
||||
current_state="HOME"
|
||||
|
|
Loading…
Reference in a new issue