2020-10-13 01:05:51 +03:00
|
|
|
function _tide_init_install --on-event _tide_init_install
|
2021-01-25 18:22:00 +03:00
|
|
|
set -U _tide_var_list
|
2021-01-27 02:33:10 +03:00
|
|
|
|
2021-01-25 18:22:00 +03:00
|
|
|
# Tiny improvment to shell startup, which makes async faster
|
|
|
|
function _tide_set -a var_name
|
|
|
|
set -U $var_name $argv[2..-1]
|
|
|
|
set -a _tide_var_list $var_name
|
|
|
|
end
|
|
|
|
|
|
|
|
_tide_set _tide_color_dark_blue 0087AF
|
|
|
|
_tide_set _tide_color_dark_green 5FAF00
|
|
|
|
_tide_set _tide_color_gold D7AF00
|
|
|
|
_tide_set _tide_color_green 5FD700
|
|
|
|
_tide_set _tide_color_light_blue 00AFFF
|
2021-03-27 19:09:56 +03:00
|
|
|
_tide_set _tide_root (status dirname)/..
|
2021-04-05 06:20:26 +03:00
|
|
|
_tide_set _tide_os_icon (_tide_detect_os)
|
2021-01-25 18:22:00 +03:00
|
|
|
_tide_set VIRTUAL_ENV_DISABLE_PROMPT true
|
2020-10-13 01:05:51 +03:00
|
|
|
|
2021-01-25 18:13:06 +03:00
|
|
|
source $_tide_root/functions/tide/configure/choices/all/style.fish
|
2021-02-17 07:57:12 +03:00
|
|
|
source $_tide_root/functions/tide/configure/choices/all/finish.fish
|
2021-03-02 20:46:40 +03:00
|
|
|
_load_config lean
|
2021-02-17 07:57:12 +03:00
|
|
|
_tide_finish
|
|
|
|
set -a _tide_var_list (set --names | string match --regex "^tide.*")
|
2020-10-13 01:05:51 +03:00
|
|
|
|
2020-12-28 20:46:47 +03:00
|
|
|
status is-interactive && switch (read --prompt-str="Configure tide prompt? [Y/n] " | string lower)
|
|
|
|
case y ye yes ''
|
|
|
|
tide configure
|
|
|
|
case '*'
|
2021-04-01 03:42:53 +03:00
|
|
|
printf '%s' \n 'Run ' (printf '%s' "tide configure" | fish_indent --ansi) ' to customize your prompt.' \n
|
2020-10-13 01:05:51 +03:00
|
|
|
end
|
|
|
|
end
|
|
|
|
|
2020-10-16 01:15:17 +03:00
|
|
|
function _tide_init_uninstall --on-event _tide_init_uninstall
|
2021-03-02 20:52:58 +03:00
|
|
|
set -e $_tide_var_list _tide_var_list
|
2020-11-03 20:23:59 +03:00
|
|
|
functions --erase (functions --all | string match --entire --regex '^_tide_')
|
2020-10-16 01:15:17 +03:00
|
|
|
end
|