Remove _set_tide_defaults in favor of lean config

This commit is contained in:
Ilan Cosman 2020-06-15 16:23:45 -07:00
parent 546f993882
commit dc624ca122
3 changed files with 8 additions and 77 deletions

View File

@ -49,8 +49,13 @@ function tide_install
_set_immutables
source "$__fish_config_dir/tide_theme/configure/functions/_set_tide_defaults.fish"
_set_tide_defaults
source "$_tide_dir/configure/configs/lean.fish"
for fakeVar in $fake_tide_var_list
set -l normalVar (string replace 'fake_' '' $fakeVar)
set -U $normalVar $$fakeVar
set -a _tide_var_list $normalVar
set -e $fakeVar
end
# -----------------------Finish-----------------------
for file in $_tide_file_list

View File

@ -20,6 +20,7 @@ function finish
set -l normalVar (string replace 'fake_' '' $fakeVar)
set -U $normalVar $$fakeVar
set -a _tide_var_list $normalVar
set -e $fakeVar
end
cd .

View File

@ -1,75 +0,0 @@
function _set_tide_defaults
set -U _tide_var_list
# -------------------Local Variables-------------------
set -l tideColorGold D7AF00
set -l tideColorDarkerGreen 5FAF00
# ---------------General Theme Variables---------------
_set tide_newline 'true'
# ---------Prompt Connection---------
_set tide_prompt_connection_color 6C6C6C
_set tide_prompt_connection_icon ' '
# --------------------Prompt Items--------------------
_set tide_left_prompt_items 'pwd' 'git_prompt' 'newline' 'prompt_char'
_set tide_right_prompt_items 'status' 'cmd_duration' 'context' 'jobs'
# ------------Prompt Char------------
_set tide_prompt_char_success_color $_tide_color_green
_set tide_prompt_char_failure_color FF0000
_set tide_prompt_char_icon ''
# ----------------Pwd----------------
_set tide_pwd_truncate_margin 10
_set tide_pwd_unwritable_icon '' # Lock
_set tide_pwd_max_dirs 0
_set tide_pwd_anchors 'first' 'last' 'git'
_set tide_pwd_color_anchors $_tide_color_light_blue
_set tide_pwd_color_dirs $_tide_color_dark_blue
_set tide_pwd_color_truncated_dirs 8787AF
# ------------Git prompt------------
_set __fish_git_prompt_show_informative_status true
_set __fish_git_prompt_showstashstate true
# -------Symbols-------
_set __fish_git_prompt_char_stateseparator ''
_set __fish_git_prompt_char_cleanstate ''
_set __fish_git_prompt_char_upstream_ahead ' ⇡'
_set __fish_git_prompt_char_upstream_behind ' ⇣'
_set __fish_git_prompt_char_stagedstate ' +'
_set __fish_git_prompt_char_dirtystate ' !'
_set __fish_git_prompt_char_untrackedfiles ' ?'
_set __fish_git_prompt_char_stashstate ' *'
# --------Colors--------
_set __fish_git_prompt_color_branch $_tide_color_green
_set __fish_git_prompt_color_upstream $_tide_color_green
_set __fish_git_prompt_color_stagedstate $tideColorGold
_set __fish_git_prompt_color_dirtystate $tideColorGold
_set __fish_git_prompt_color_untrackedfiles $_tide_color_light_blue
_set __fish_git_prompt_color_stashstate $_tide_color_green
# --------------Status--------------
_set tide_status_success_icon '✔'
_set tide_status_success_color $tideColorDarkerGreen
_set tide_status_failure_icon '✘'
_set tide_status_failure_color D70000
# -----------Cmd_Duration-----------
_set tide_cmd_duration_color 87875F
_set tide_cmd_duration_decimals 0
_set tide_cmd_duration_threshold 3000
# --------------Context--------------
_set tide_context_ssh_color D7AF87
_set tide_context_root_color $tideColorGold
# ---------------Jobs---------------
_set tide_jobs_icon '' # Gear
_set tide_jobs_color $tideColorDarkerGreen
# ---------------Time---------------
_set tide_time_color 5F8787
_set tide_time_format '%T'
cat "$_tide_dir/configure/fish_prompt.fish" >"$__fish_config_dir/functions/fish_prompt.fish"
end
function _set -a var_name
set -U $var_name $argv[2..-1]
set -a _tide_var_list $var_name
end