From b88d77fb2d0d5028a6f5670695dee6bec129501f Mon Sep 17 00:00:00 2001 From: Ryan Schanzenbacher Date: Fri, 5 Apr 2024 11:57:45 -0400 Subject: ahhh sloppy fish, still needs fixing, esp with the vars --- .../tide/configure/choices/all/finish.fish | 46 ++++++++ .../tide/configure/choices/all/icons.fish | 33 ++++++ .../tide/configure/choices/all/prompt_colors.fish | 26 +++++ .../configure/choices/all/prompt_connection.fish | 31 ++++++ .../all/prompt_connection_andor_frame_color.fish | 40 +++++++ .../tide/configure/choices/all/prompt_spacing.fish | 22 ++++ .../tide/configure/choices/all/show_time.fish | 33 ++++++ .../tide/configure/choices/all/style.fish | 36 +++++++ .../tide/configure/choices/all/transient.fish | 22 ++++ .../choices/classic/classic_prompt_color.fish | 38 +++++++ .../choices/classic/classic_prompt_separators.fish | 40 +++++++ .../configure/choices/lean/lean_prompt_height.fish | 26 +++++ .../choices/powerline/powerline_prompt_heads.fish | 32 ++++++ .../choices/powerline/powerline_prompt_style.fish | 51 +++++++++ .../choices/powerline/powerline_prompt_tails.fish | 40 +++++++ .../powerline/powerline_right_prompt_frame.fish | 20 ++++ .../choices/rainbow/rainbow_prompt_separators.fish | 40 +++++++ .../functions/tide/configure/configs/classic.fish | 116 +++++++++++++++++++++ .../tide/configure/configs/classic_16color.fish | 89 ++++++++++++++++ .../functions/tide/configure/configs/lean.fish | 116 +++++++++++++++++++++ .../tide/configure/configs/lean_16color.fish | 89 ++++++++++++++++ .../functions/tide/configure/configs/rainbow.fish | 116 +++++++++++++++++++++ .../tide/configure/configs/rainbow_16color.fish | 93 +++++++++++++++++ .../functions/_fake_tide_cache_variables.fish | 41 ++++++++ .../functions/_fake_tide_item_character.fish | 8 ++ .../functions/_fake_tide_item_cmd_duration.fish | 3 + .../configure/functions/_fake_tide_item_git.fish | 3 + .../functions/_fake_tide_item_newline.fish | 5 + .../configure/functions/_fake_tide_item_os.fish | 3 + .../configure/functions/_fake_tide_item_time.fish | 3 + .../configure/functions/_fake_tide_print_item.fish | 22 ++++ .../configure/functions/_fake_tide_prompt.fish | 42 ++++++++ .../tide/configure/functions/_fake_tide_pwd.fish | 11 ++ .../fish/functions/tide/configure/icons.fish | 40 +++++++ 34 files changed, 1376 insertions(+) create mode 100644 home-config/fish/functions/tide/configure/choices/all/finish.fish create mode 100644 home-config/fish/functions/tide/configure/choices/all/icons.fish create mode 100644 home-config/fish/functions/tide/configure/choices/all/prompt_colors.fish create mode 100644 home-config/fish/functions/tide/configure/choices/all/prompt_connection.fish create mode 100644 home-config/fish/functions/tide/configure/choices/all/prompt_connection_andor_frame_color.fish create mode 100644 home-config/fish/functions/tide/configure/choices/all/prompt_spacing.fish create mode 100644 home-config/fish/functions/tide/configure/choices/all/show_time.fish create mode 100644 home-config/fish/functions/tide/configure/choices/all/style.fish create mode 100644 home-config/fish/functions/tide/configure/choices/all/transient.fish create mode 100644 home-config/fish/functions/tide/configure/choices/classic/classic_prompt_color.fish create mode 100644 home-config/fish/functions/tide/configure/choices/classic/classic_prompt_separators.fish create mode 100644 home-config/fish/functions/tide/configure/choices/lean/lean_prompt_height.fish create mode 100644 home-config/fish/functions/tide/configure/choices/powerline/powerline_prompt_heads.fish create mode 100644 home-config/fish/functions/tide/configure/choices/powerline/powerline_prompt_style.fish create mode 100644 home-config/fish/functions/tide/configure/choices/powerline/powerline_prompt_tails.fish create mode 100644 home-config/fish/functions/tide/configure/choices/powerline/powerline_right_prompt_frame.fish create mode 100644 home-config/fish/functions/tide/configure/choices/rainbow/rainbow_prompt_separators.fish create mode 100644 home-config/fish/functions/tide/configure/configs/classic.fish create mode 100644 home-config/fish/functions/tide/configure/configs/classic_16color.fish create mode 100644 home-config/fish/functions/tide/configure/configs/lean.fish create mode 100644 home-config/fish/functions/tide/configure/configs/lean_16color.fish create mode 100644 home-config/fish/functions/tide/configure/configs/rainbow.fish create mode 100644 home-config/fish/functions/tide/configure/configs/rainbow_16color.fish create mode 100644 home-config/fish/functions/tide/configure/functions/_fake_tide_cache_variables.fish create mode 100644 home-config/fish/functions/tide/configure/functions/_fake_tide_item_character.fish create mode 100644 home-config/fish/functions/tide/configure/functions/_fake_tide_item_cmd_duration.fish create mode 100644 home-config/fish/functions/tide/configure/functions/_fake_tide_item_git.fish create mode 100644 home-config/fish/functions/tide/configure/functions/_fake_tide_item_newline.fish create mode 100644 home-config/fish/functions/tide/configure/functions/_fake_tide_item_os.fish create mode 100644 home-config/fish/functions/tide/configure/functions/_fake_tide_item_time.fish create mode 100644 home-config/fish/functions/tide/configure/functions/_fake_tide_print_item.fish create mode 100644 home-config/fish/functions/tide/configure/functions/_fake_tide_prompt.fish create mode 100644 home-config/fish/functions/tide/configure/functions/_fake_tide_pwd.fish create mode 100644 home-config/fish/functions/tide/configure/icons.fish (limited to 'home-config/fish/functions/tide/configure') diff --git a/home-config/fish/functions/tide/configure/choices/all/finish.fish b/home-config/fish/functions/tide/configure/choices/all/finish.fish new file mode 100644 index 0000000..f670b1e --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/all/finish.fish @@ -0,0 +1,46 @@ +function finish + _tide_title Finish + + echo + set_color red + _tide_option y 'Overwrite your current tide config' + set_color normal + echo + + _tide_option p 'Exit and print the config you just generated' + echo + + _tide_menu (status function) + switch $_tide_selected_option + case 'Overwrite your current tide config' + _tide_finish + command -q clear && clear + set -q _flag_auto || _tide_print_configure_current_options + case 'Exit and print the config you just generated' + _tide_exit_configure + command -q clear && clear + _tide_print_configure_current_options + end +end + +function _tide_finish + _tide_exit_configure + + # Deal with prompt char/vi mode + contains character $fake_tide_left_prompt_items || set -p fake_tide_left_prompt_items vi_mode + + # Set the real variables + for fakeVar in (set --names | string match -r "^fake_tide.*") + set -U (string replace 'fake_' '' $fakeVar) $$fakeVar + end + + # Make sure old prompt won't display + set -e $_tide_prompt_var 2>/dev/null + + # Re-initialize the prompt + tide reload +end + +function _tide_print_configure_current_options + _tide_fish_colorize "tide configure --auto $_tide_configure_current_options" +end diff --git a/home-config/fish/functions/tide/configure/choices/all/icons.fish b/home-config/fish/functions/tide/configure/choices/all/icons.fish new file mode 100644 index 0000000..be167bb --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/all/icons.fish @@ -0,0 +1,33 @@ +function icons + _tide_title Icons + + _tide_option 1 'Few icons' + _tide_display_prompt + + _tide_option 2 'Many icons' + _enable_icons + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case 'Few icons' + _disable_icons + end + _next_choice all/transient +end + +function _enable_icons + set -p fake_tide_left_prompt_items os + set -g fake_tide_pwd_icon  + set -g fake_tide_pwd_icon_home  + set -g fake_tide_cmd_duration_icon  + set -g fake_tide_git_icon  +end + +function _disable_icons + _tide_find_and_remove os fake_tide_left_prompt_items + set fake_tide_pwd_icon + set fake_tide_pwd_icon_home + set fake_tide_cmd_duration_icon + set fake_tide_git_icon +end diff --git a/home-config/fish/functions/tide/configure/choices/all/prompt_colors.fish b/home-config/fish/functions/tide/configure/choices/all/prompt_colors.fish new file mode 100644 index 0000000..247ef4e --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/all/prompt_colors.fish @@ -0,0 +1,26 @@ +function prompt_colors + _tide_title 'Prompt Colors' + + _tide_option 1 'True color' + _tide_display_prompt + + _tide_option 2 '16 colors' + _load_config "$_tide_configure_style"_16color + set -g _tide_16color true + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case 'True color' + _load_config "$_tide_configure_style" + set -e _tide_16color + switch $_tide_configure_style + case lean rainbow + _next_choice all/show_time + case classic + _next_choice classic/classic_prompt_color + end + case '16 colors' + _next_choice all/show_time + end +end diff --git a/home-config/fish/functions/tide/configure/choices/all/prompt_connection.fish b/home-config/fish/functions/tide/configure/choices/all/prompt_connection.fish new file mode 100644 index 0000000..ff76546 --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/all/prompt_connection.fish @@ -0,0 +1,31 @@ +function prompt_connection + _tide_title 'Prompt Connection' + + _tide_option 1 Disconnected + set -g fake_tide_prompt_icon_connection ' ' + _tide_display_prompt + + _tide_option 2 Dotted + set -g fake_tide_prompt_icon_connection '·' + _tide_display_prompt + + _tide_option 3 Solid + set -g fake_tide_prompt_icon_connection '─' + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case Disconnected + set -g fake_tide_prompt_icon_connection ' ' + case Dotted + set -g fake_tide_prompt_icon_connection '·' + case Solid + set -g fake_tide_prompt_icon_connection '─' + end + switch $_tide_configure_style + case lean + _next_choice all/prompt_connection_andor_frame_color + case classic rainbow + _next_choice powerline/powerline_right_prompt_frame + end +end diff --git a/home-config/fish/functions/tide/configure/choices/all/prompt_connection_andor_frame_color.fish b/home-config/fish/functions/tide/configure/choices/all/prompt_connection_andor_frame_color.fish new file mode 100644 index 0000000..cefbf2c --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/all/prompt_connection_andor_frame_color.fish @@ -0,0 +1,40 @@ +function prompt_connection_andor_frame_color + if test "$_tide_16color" = true || + test "$fake_tide_left_prompt_frame_enabled" = false -a \ + "$fake_tide_right_prompt_frame_enabled" = false -a \ + "$fake_tide_prompt_icon_connection" = ' ' + _next_choice all/prompt_spacing + return 0 + end + + _tide_title "Connection & Frame Color" + + _tide_option 1 Lightest + set -g fake_tide_prompt_color_frame_and_connection 808080 + _tide_display_prompt + + _tide_option 2 Light + set -g fake_tide_prompt_color_frame_and_connection 6C6C6C + _tide_display_prompt + + _tide_option 3 Dark + set -g fake_tide_prompt_color_frame_and_connection 585858 + _tide_display_prompt + + _tide_option 4 Darkest + set -g fake_tide_prompt_color_frame_and_connection 444444 + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case Lightest + set -g fake_tide_prompt_color_frame_and_connection 808080 + case Light + set -g fake_tide_prompt_color_frame_and_connection 6C6C6C + case Dark + set -g fake_tide_prompt_color_frame_and_connection 585858 + case Darkest + set -g fake_tide_prompt_color_frame_and_connection 444444 + end + _next_choice all/prompt_spacing +end diff --git a/home-config/fish/functions/tide/configure/choices/all/prompt_spacing.fish b/home-config/fish/functions/tide/configure/choices/all/prompt_spacing.fish new file mode 100644 index 0000000..f68be68 --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/all/prompt_spacing.fish @@ -0,0 +1,22 @@ +function prompt_spacing + _tide_title 'Prompt Spacing' + + _tide_option 1 Compact + set -g fake_tide_prompt_add_newline_before false + _tide_display_prompt + _tide_display_prompt + + _tide_option 2 Sparse + set -g fake_tide_prompt_add_newline_before true + _tide_display_prompt + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case Compact + set -g fake_tide_prompt_add_newline_before false + case Sparse + set -g fake_tide_prompt_add_newline_before true + end + _next_choice all/icons +end diff --git a/home-config/fish/functions/tide/configure/choices/all/show_time.fish b/home-config/fish/functions/tide/configure/choices/all/show_time.fish new file mode 100644 index 0000000..b66c785 --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/all/show_time.fish @@ -0,0 +1,33 @@ +function show_time + _tide_title 'Show current time?' + + _tide_option 1 No + _tide_display_prompt + + set -a fake_tide_right_prompt_items time + + _tide_option 2 '24-hour format' + set -g fake_tide_time_format %T + _tide_display_prompt + + _tide_option 3 '12-hour format' + set -g fake_tide_time_format %r + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case No + set -g fake_tide_time_format '' + set -e fake_tide_right_prompt_items[-1] + case '24-hour format' + set -g fake_tide_time_format %T + case '12-hour format' + set -g fake_tide_time_format %r + end + switch $_tide_configure_style + case lean + _next_choice "$_tide_configure_style"/"$_tide_configure_style"_prompt_height + case classic rainbow + _next_choice "$_tide_configure_style"/"$_tide_configure_style"_prompt_separators + end +end diff --git a/home-config/fish/functions/tide/configure/choices/all/style.fish b/home-config/fish/functions/tide/configure/choices/all/style.fish new file mode 100644 index 0000000..fe9a58f --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/all/style.fish @@ -0,0 +1,36 @@ +function style + set -g _tide_configure_current_options + + _tide_title 'Prompt Style' + + _tide_option 1 Lean + _load_config lean + _tide_display_prompt + + _tide_option 2 Classic + _load_config classic + _tide_display_prompt + + _tide_option 3 Rainbow + _load_config rainbow + _tide_display_prompt + + _tide_menu (status function) --no-restart + switch $_tide_selected_option + case Lean + _load_config lean + set -g _tide_configure_style lean + case Classic + _load_config classic + set -g _tide_configure_style classic + case Rainbow + _load_config rainbow + set -g _tide_configure_style rainbow + end + _next_choice all/prompt_colors +end + +function _load_config -a name + string replace -r '^' 'set -g fake_' <(status dirname)/../../icons.fish | source + string replace -r '^' 'set -g fake_' <(status dirname)/../../configs/$name.fish | source +end diff --git a/home-config/fish/functions/tide/configure/choices/all/transient.fish b/home-config/fish/functions/tide/configure/choices/all/transient.fish new file mode 100644 index 0000000..df2b6b6 --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/all/transient.fish @@ -0,0 +1,22 @@ +function transient + _tide_title 'Enable transient prompt?' + + _tide_option 1 No + _tide_display_prompt + _tide_display_prompt + _tide_display_prompt + + _tide_option 2 Yes + _configure_transient= _tide_display_prompt + _configure_transient= _tide_display_prompt + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case No + set fake_tide_prompt_transient_enabled false + case Yes + set fake_tide_prompt_transient_enabled true + end + _next_choice all/finish +end diff --git a/home-config/fish/functions/tide/configure/choices/classic/classic_prompt_color.fish b/home-config/fish/functions/tide/configure/choices/classic/classic_prompt_color.fish new file mode 100644 index 0000000..77ceeaf --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/classic/classic_prompt_color.fish @@ -0,0 +1,38 @@ +function classic_prompt_color + _tide_title 'Prompt Color' + + _tide_option 1 Lightest + _set_all_items_bg_color 585858 + _tide_display_prompt + + _tide_option 2 Light + _set_all_items_bg_color 444444 + _tide_display_prompt + + _tide_option 3 Dark + _set_all_items_bg_color 303030 + _tide_display_prompt + + _tide_option 4 Darkest + _set_all_items_bg_color 1C1C1C + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case Lightest + _set_all_items_bg_color 585858 + case Light + _set_all_items_bg_color 444444 + case Dark + _set_all_items_bg_color 303030 + case Darkest + _set_all_items_bg_color 1C1C1C + end + _next_choice all/show_time +end + +function _set_all_items_bg_color -a color + for var in (set --names | string match -r "fake_.*_bg_color.*") + set $var $color + end +end diff --git a/home-config/fish/functions/tide/configure/choices/classic/classic_prompt_separators.fish b/home-config/fish/functions/tide/configure/choices/classic/classic_prompt_separators.fish new file mode 100644 index 0000000..20af6cd --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/classic/classic_prompt_separators.fish @@ -0,0 +1,40 @@ +function classic_prompt_separators + _tide_title 'Prompt Separators' + + _tide_option 1 Angled + set -g fake_tide_left_prompt_separator_same_color  + set -g fake_tide_right_prompt_separator_same_color  + _tide_display_prompt + + _tide_option 2 Vertical + set -g fake_tide_left_prompt_separator_same_color │ + set -g fake_tide_right_prompt_separator_same_color │ + _tide_display_prompt + + _tide_option 3 Slanted + set -g fake_tide_left_prompt_separator_same_color ╱ + set -g fake_tide_right_prompt_separator_same_color ╱ + _tide_display_prompt + + _tide_option 4 Round + set -g fake_tide_left_prompt_separator_same_color  + set -g fake_tide_right_prompt_separator_same_color  + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case Angled + set -g fake_tide_left_prompt_separator_same_color  + set -g fake_tide_right_prompt_separator_same_color  + case Vertical + set -g fake_tide_left_prompt_separator_same_color │ + set -g fake_tide_right_prompt_separator_same_color │ + case Slanted + set -g fake_tide_left_prompt_separator_same_color ╱ + set -g fake_tide_right_prompt_separator_same_color ╱ + case Round + set -g fake_tide_left_prompt_separator_same_color  + set -g fake_tide_right_prompt_separator_same_color  + end + _next_choice powerline/powerline_prompt_heads +end diff --git a/home-config/fish/functions/tide/configure/choices/lean/lean_prompt_height.fish b/home-config/fish/functions/tide/configure/choices/lean/lean_prompt_height.fish new file mode 100644 index 0000000..2077241 --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/lean/lean_prompt_height.fish @@ -0,0 +1,26 @@ +function lean_prompt_height + _tide_title 'Prompt Height' + + _tide_option 1 'One line' + _tide_find_and_remove newline fake_tide_left_prompt_items + set -g fake_tide_left_prompt_suffix '' + _tide_display_prompt + + _tide_option 2 'Two lines' + set -g fake_tide_left_prompt_items $fake_tide_left_prompt_items[1..-2] newline $fake_tide_left_prompt_items[-1] + set -g fake_tide_left_prompt_suffix ' ' + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case 'One line' + _tide_find_and_remove newline fake_tide_left_prompt_items + set fake_tide_left_prompt_suffix '' + _next_choice all/prompt_connection_andor_frame_color + case 'Two lines' + _tide_find_and_remove newline fake_tide_left_prompt_items + set -g fake_tide_left_prompt_items $fake_tide_left_prompt_items[1..-2] newline $fake_tide_left_prompt_items[-1] + set -g fake_tide_left_prompt_suffix ' ' + _next_choice all/prompt_connection + end +end diff --git a/home-config/fish/functions/tide/configure/choices/powerline/powerline_prompt_heads.fish b/home-config/fish/functions/tide/configure/choices/powerline/powerline_prompt_heads.fish new file mode 100644 index 0000000..0030cad --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/powerline/powerline_prompt_heads.fish @@ -0,0 +1,32 @@ +function powerline_prompt_heads + _tide_title 'Prompt Heads' + + _tide_option 1 Sharp + set -g fake_tide_left_prompt_suffix  + set -g fake_tide_right_prompt_prefix  + _tide_display_prompt + + _tide_option 2 Slanted + set -g fake_tide_left_prompt_suffix  + set -g fake_tide_right_prompt_prefix  + _tide_display_prompt + + _tide_option 3 Round + set -g fake_tide_left_prompt_suffix  + set -g fake_tide_right_prompt_prefix  + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case Sharp + set -g fake_tide_left_prompt_suffix  + set -g fake_tide_right_prompt_prefix  + case Slanted + set -g fake_tide_left_prompt_suffix  + set -g fake_tide_right_prompt_prefix  + case Round + set -g fake_tide_left_prompt_suffix  + set -g fake_tide_right_prompt_prefix  + end + _next_choice powerline/powerline_prompt_tails +end diff --git a/home-config/fish/functions/tide/configure/choices/powerline/powerline_prompt_style.fish b/home-config/fish/functions/tide/configure/choices/powerline/powerline_prompt_style.fish new file mode 100644 index 0000000..b374757 --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/powerline/powerline_prompt_style.fish @@ -0,0 +1,51 @@ +function powerline_prompt_style + _tide_title 'Powerline Prompt Style' + + _tide_option 1 'One line' + _tide_find_and_remove newline fake_tide_left_prompt_items + _tide_find_and_remove character fake_tide_left_prompt_items + set fake_tide_left_prompt_frame_enabled false + set fake_tide_right_prompt_frame_enabled false + _tide_display_prompt + + set -a fake_tide_left_prompt_items newline + + _tide_option 2 'Two lines, character' + set -a fake_tide_left_prompt_items character + set fake_tide_left_prompt_frame_enabled false + set fake_tide_right_prompt_frame_enabled false + _tide_display_prompt + + _tide_option 3 'Two lines, frame' + _tide_find_and_remove character fake_tide_left_prompt_items + set fake_tide_left_prompt_frame_enabled true + set fake_tide_right_prompt_frame_enabled true + _tide_display_prompt + + _tide_option 4 'Two lines, character and frame' + set -a fake_tide_left_prompt_items character + set fake_tide_left_prompt_frame_enabled true + set fake_tide_right_prompt_frame_enabled true + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case 'One line' + _tide_find_and_remove newline fake_tide_left_prompt_items + _tide_find_and_remove character fake_tide_left_prompt_items + set fake_tide_left_prompt_frame_enabled false + set fake_tide_right_prompt_frame_enabled false + _next_choice all/prompt_connection_andor_frame_color + case 'Two lines, character' + set fake_tide_left_prompt_frame_enabled false + set fake_tide_right_prompt_frame_enabled false + _next_choice all/prompt_connection + case 'Two lines, frame' + _tide_find_and_remove character fake_tide_left_prompt_items + set fake_tide_left_prompt_frame_enabled true + set fake_tide_right_prompt_frame_enabled true + _next_choice all/prompt_connection + case 'Two lines, character and frame' + _next_choice all/prompt_connection + end +end diff --git a/home-config/fish/functions/tide/configure/choices/powerline/powerline_prompt_tails.fish b/home-config/fish/functions/tide/configure/choices/powerline/powerline_prompt_tails.fish new file mode 100644 index 0000000..6b1574b --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/powerline/powerline_prompt_tails.fish @@ -0,0 +1,40 @@ +function powerline_prompt_tails + _tide_title 'Prompt Tails' + + _tide_option 1 Flat + set -g fake_tide_left_prompt_prefix '' + set -g fake_tide_right_prompt_suffix '' + _tide_display_prompt + + _tide_option 2 Sharp + set -g fake_tide_left_prompt_prefix  + set -g fake_tide_right_prompt_suffix  + _tide_display_prompt + + _tide_option 3 Slanted + set -g fake_tide_left_prompt_prefix  + set -g fake_tide_right_prompt_suffix  + _tide_display_prompt + + _tide_option 4 Round + set -g fake_tide_left_prompt_prefix  + set -g fake_tide_right_prompt_suffix  + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case Flat + set -g fake_tide_left_prompt_prefix '' + set -g fake_tide_right_prompt_suffix '' + case Sharp + set -g fake_tide_left_prompt_prefix  + set -g fake_tide_right_prompt_suffix  + case Slanted + set -g fake_tide_left_prompt_prefix  + set -g fake_tide_right_prompt_suffix  + case Round + set -g fake_tide_left_prompt_prefix  + set -g fake_tide_right_prompt_suffix  + end + _next_choice powerline/powerline_prompt_style +end diff --git a/home-config/fish/functions/tide/configure/choices/powerline/powerline_right_prompt_frame.fish b/home-config/fish/functions/tide/configure/choices/powerline/powerline_right_prompt_frame.fish new file mode 100644 index 0000000..a2d0a5b --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/powerline/powerline_right_prompt_frame.fish @@ -0,0 +1,20 @@ +function powerline_right_prompt_frame + _tide_title 'Right Prompt Frame' + + _tide_option 1 No + set fake_tide_right_prompt_frame_enabled false + _tide_display_prompt + + _tide_option 2 Yes + set fake_tide_right_prompt_frame_enabled true + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case No + set fake_tide_right_prompt_frame_enabled false + case Yes + set fake_tide_right_prompt_frame_enabled true + end + _next_choice all/prompt_connection_andor_frame_color +end diff --git a/home-config/fish/functions/tide/configure/choices/rainbow/rainbow_prompt_separators.fish b/home-config/fish/functions/tide/configure/choices/rainbow/rainbow_prompt_separators.fish new file mode 100644 index 0000000..14b9319 --- /dev/null +++ b/home-config/fish/functions/tide/configure/choices/rainbow/rainbow_prompt_separators.fish @@ -0,0 +1,40 @@ +function rainbow_prompt_separators + _tide_title 'Prompt Separators' + + _tide_option 1 Angled + set -g fake_tide_left_prompt_separator_diff_color  + set -g fake_tide_right_prompt_separator_diff_color  + _tide_display_prompt + + _tide_option 2 Vertical + set -g fake_tide_left_prompt_separator_diff_color '' + set -g fake_tide_right_prompt_separator_diff_color '' + _tide_display_prompt + + _tide_option 3 Slanted + set -g fake_tide_left_prompt_separator_diff_color '' + set -g fake_tide_right_prompt_separator_diff_color '' + _tide_display_prompt + + _tide_option 4 Round + set -g fake_tide_left_prompt_separator_diff_color '' + set -g fake_tide_right_prompt_separator_diff_color '' + _tide_display_prompt + + _tide_menu (status function) + switch $_tide_selected_option + case Angled + set -g fake_tide_left_prompt_separator_diff_color  + set -g fake_tide_right_prompt_separator_diff_color  + case Vertical + set -g fake_tide_left_prompt_separator_diff_color '' + set -g fake_tide_right_prompt_separator_diff_color '' + case Slanted + set -g fake_tide_left_prompt_separator_diff_color '' + set -g fake_tide_right_prompt_separator_diff_color '' + case Round + set -g fake_tide_left_prompt_separator_diff_color '' + set -g fake_tide_right_prompt_separator_diff_color '' + end + _next_choice powerline/powerline_prompt_heads +end diff --git a/home-config/fish/functions/tide/configure/configs/classic.fish b/home-config/fish/functions/tide/configure/configs/classic.fish new file mode 100644 index 0000000..8973cbc --- /dev/null +++ b/home-config/fish/functions/tide/configure/configs/classic.fish @@ -0,0 +1,116 @@ +tide_aws_bg_color 444444 +tide_aws_color FF9900 +tide_character_color $_tide_color_green +tide_character_color_failure FF0000 +tide_cmd_duration_bg_color 444444 +tide_cmd_duration_color 87875F +tide_cmd_duration_decimals 0 +tide_cmd_duration_threshold 3000 +tide_context_always_display false +tide_context_bg_color 444444 +tide_context_color_default D7AF87 +tide_context_color_root $_tide_color_gold +tide_context_color_ssh D7AF87 +tide_context_hostname_parts 1 +tide_crystal_bg_color 444444 +tide_crystal_color FFFFFF +tide_direnv_bg_color 444444 +tide_direnv_bg_color_denied 444444 +tide_direnv_color $_tide_color_gold +tide_direnv_color_denied FF0000 +tide_distrobox_bg_color 444444 +tide_distrobox_color FF00FF +tide_docker_bg_color 444444 +tide_docker_color 2496ED +tide_docker_default_contexts default colima +tide_elixir_bg_color 444444 +tide_elixir_color 4E2A8E +tide_gcloud_bg_color 444444 +tide_gcloud_color 4285F4 +tide_git_bg_color 444444 +tide_git_bg_color_unstable 444444 +tide_git_bg_color_urgent 444444 +tide_git_color_branch $_tide_color_green +tide_git_color_conflicted FF0000 +tide_git_color_dirty $_tide_color_gold +tide_git_color_operation FF0000 +tide_git_color_staged $_tide_color_gold +tide_git_color_stash $_tide_color_green +tide_git_color_untracked $_tide_color_light_blue +tide_git_color_upstream $_tide_color_green +tide_git_truncation_length 24 +tide_git_truncation_strategy +tide_go_bg_color 444444 +tide_go_color 00ACD7 +tide_java_bg_color 444444 +tide_java_color ED8B00 +tide_jobs_bg_color 444444 +tide_jobs_color $_tide_color_dark_green +tide_jobs_number_threshold 1000 +tide_kubectl_bg_color 444444 +tide_kubectl_color 326CE5 +tide_left_prompt_frame_enabled true +tide_left_prompt_items pwd git newline +tide_left_prompt_prefix '' +tide_left_prompt_separator_diff_color  +tide_left_prompt_separator_same_color  +tide_left_prompt_suffix  +tide_nix_shell_bg_color 444444 +tide_nix_shell_color 7EBAE4 +tide_node_bg_color 444444 +tide_node_color 44883E +tide_os_bg_color 444444 +tide_os_color EEEEEE +tide_php_bg_color 444444 +tide_php_color 617CBE +tide_private_mode_bg_color 444444 +tide_private_mode_color FFFFFF +tide_prompt_add_newline_before true +tide_prompt_color_frame_and_connection 6C6C6C +tide_prompt_color_separator_same_color 949494 +tide_prompt_min_cols 34 +tide_prompt_pad_items true +tide_prompt_transient_enabled false +tide_pulumi_bg_color 444444 +tide_pulumi_color F7BF2A +tide_pwd_bg_color 444444 +tide_pwd_color_anchors $_tide_color_light_blue +tide_pwd_color_dirs $_tide_color_dark_blue +tide_pwd_color_truncated_dirs 8787AF +tide_pwd_markers .bzr .citc .git .hg .node-version .python-version .ruby-version .shorten_folder_marker .svn .terraform Cargo.toml composer.json CVS go.mod package.json build.zig +tide_python_bg_color 444444 +tide_python_color 00AFAF +tide_right_prompt_frame_enabled true +tide_right_prompt_items status cmd_duration context jobs direnv node python rustc java php pulumi ruby go gcloud kubectl distrobox toolbox terraform aws nix_shell crystal elixir zig +tide_right_prompt_prefix  +tide_right_prompt_separator_diff_color  +tide_right_prompt_separator_same_color  +tide_right_prompt_suffix '' +tide_ruby_bg_color 444444 +tide_ruby_color B31209 +tide_rustc_bg_color 444444 +tide_rustc_color F74C00 +tide_shlvl_bg_color 444444 +tide_shlvl_color d78700 +tide_shlvl_threshold 1 +tide_status_bg_color 444444 +tide_status_bg_color_failure 444444 +tide_status_color $_tide_color_dark_green +tide_status_color_failure D70000 +tide_terraform_bg_color 444444 +tide_terraform_color 844FBA +tide_time_bg_color 444444 +tide_time_color 5F8787 +tide_time_format %T +tide_toolbox_bg_color 444444 +tide_toolbox_color 613583 +tide_vi_mode_bg_color_default 444444 +tide_vi_mode_bg_color_insert 444444 +tide_vi_mode_bg_color_replace 444444 +tide_vi_mode_bg_color_visual 444444 +tide_vi_mode_color_default 949494 +tide_vi_mode_color_insert 87AFAF +tide_vi_mode_color_replace 87AF87 +tide_vi_mode_color_visual FF8700 +tide_zig_bg_color 444444 +tide_zig_color F7A41D diff --git a/home-config/fish/functions/tide/configure/configs/classic_16color.fish b/home-config/fish/functions/tide/configure/configs/classic_16color.fish new file mode 100644 index 0000000..670170f --- /dev/null +++ b/home-config/fish/functions/tide/configure/configs/classic_16color.fish @@ -0,0 +1,89 @@ +tide_aws_bg_color black +tide_aws_color yellow +tide_character_color brgreen +tide_character_color_failure brred +tide_cmd_duration_bg_color black +tide_cmd_duration_color brblack +tide_context_bg_color black +tide_context_color_default yellow +tide_context_color_root bryellow +tide_context_color_ssh yellow +tide_crystal_bg_color black +tide_crystal_color brwhite +tide_direnv_bg_color black +tide_direnv_bg_color_denied black +tide_direnv_color bryellow +tide_direnv_color_denied brred +tide_distrobox_bg_color black +tide_distrobox_color brmagenta +tide_docker_bg_color black +tide_docker_color blue +tide_elixir_bg_color black +tide_elixir_color magenta +tide_gcloud_bg_color black +tide_gcloud_color blue +tide_git_bg_color black +tide_git_bg_color_unstable black +tide_git_bg_color_urgent black +tide_git_color_branch brgreen +tide_git_color_conflicted brred +tide_git_color_dirty bryellow +tide_git_color_operation brred +tide_git_color_staged bryellow +tide_git_color_stash brgreen +tide_git_color_untracked brblue +tide_git_color_upstream brgreen +tide_go_bg_color black +tide_go_color brcyan +tide_java_bg_color black +tide_java_color yellow +tide_jobs_bg_color black +tide_jobs_color green +tide_kubectl_bg_color black +tide_kubectl_color blue +tide_nix_shell_bg_color black +tide_nix_shell_color brblue +tide_node_bg_color black +tide_node_color green +tide_os_bg_color black +tide_os_color brwhite +tide_php_bg_color black +tide_php_color blue +tide_private_mode_bg_color black +tide_private_mode_color brwhite +tide_prompt_color_frame_and_connection brblack +tide_prompt_color_separator_same_color brblack +tide_pulumi_bg_color black +tide_pulumi_color yellow +tide_pwd_bg_color black +tide_pwd_color_anchors brcyan +tide_pwd_color_dirs cyan +tide_pwd_color_truncated_dirs magenta +tide_python_bg_color black +tide_python_color cyan +tide_ruby_bg_color black +tide_ruby_color red +tide_rustc_bg_color black +tide_rustc_color red +tide_shlvl_bg_color black +tide_shlvl_color yellow +tide_status_bg_color black +tide_status_bg_color_failure black +tide_status_color green +tide_status_color_failure red +tide_terraform_bg_color black +tide_terraform_color magenta +tide_time_bg_color black +tide_time_color brblack +tide_toolbox_bg_color black +tide_toolbox_color magenta +tide_vi_mode_bg_color_default black +tide_vi_mode_bg_color_insert black +tide_vi_mode_bg_color_replace black +tide_vi_mode_bg_color_visual black +tide_vi_mode_color_default white +tide_vi_mode_color_insert cyan +tide_vi_mode_color_replace green +tide_vi_mode_color_visual yellow +tide_zig_bg_color black +tide_zig_color yellow diff --git a/home-config/fish/functions/tide/configure/configs/lean.fish b/home-config/fish/functions/tide/configure/configs/lean.fish new file mode 100644 index 0000000..a958a17 --- /dev/null +++ b/home-config/fish/functions/tide/configure/configs/lean.fish @@ -0,0 +1,116 @@ +tide_aws_bg_color normal +tide_aws_color FF9900 +tide_character_color $_tide_color_green +tide_character_color_failure FF0000 +tide_cmd_duration_bg_color normal +tide_cmd_duration_color 87875F +tide_cmd_duration_decimals 0 +tide_cmd_duration_threshold 3000 +tide_context_always_display false +tide_context_bg_color normal +tide_context_color_default D7AF87 +tide_context_color_root $_tide_color_gold +tide_context_color_ssh D7AF87 +tide_context_hostname_parts 1 +tide_crystal_bg_color normal +tide_crystal_color FFFFFF +tide_direnv_bg_color normal +tide_direnv_bg_color_denied normal +tide_direnv_color $_tide_color_gold +tide_direnv_color_denied FF0000 +tide_distrobox_bg_color normal +tide_distrobox_color FF00FF +tide_docker_bg_color normal +tide_docker_color 2496ED +tide_docker_default_contexts default colima +tide_elixir_bg_color normal +tide_elixir_color 4E2A8E +tide_gcloud_bg_color normal +tide_gcloud_color 4285F4 +tide_git_bg_color normal +tide_git_bg_color_unstable normal +tide_git_bg_color_urgent normal +tide_git_color_branch $_tide_color_green +tide_git_color_conflicted FF0000 +tide_git_color_dirty $_tide_color_gold +tide_git_color_operation FF0000 +tide_git_color_staged $_tide_color_gold +tide_git_color_stash $_tide_color_green +tide_git_color_untracked $_tide_color_light_blue +tide_git_color_upstream $_tide_color_green +tide_git_truncation_length 24 +tide_git_truncation_strategy +tide_go_bg_color normal +tide_go_color 00ACD7 +tide_java_bg_color normal +tide_java_color ED8B00 +tide_jobs_bg_color normal +tide_jobs_color $_tide_color_dark_green +tide_jobs_number_threshold 1000 +tide_kubectl_bg_color normal +tide_kubectl_color 326CE5 +tide_left_prompt_frame_enabled false +tide_left_prompt_items pwd git newline character +tide_left_prompt_prefix '' +tide_left_prompt_separator_diff_color ' ' +tide_left_prompt_separator_same_color ' ' +tide_left_prompt_suffix ' ' +tide_nix_shell_bg_color normal +tide_nix_shell_color 7EBAE4 +tide_node_bg_color normal +tide_node_color 44883E +tide_os_bg_color normal +tide_os_color normal +tide_php_bg_color normal +tide_php_color 617CBE +tide_private_mode_bg_color normal +tide_private_mode_color FFFFFF +tide_prompt_add_newline_before true +tide_prompt_color_frame_and_connection 6C6C6C +tide_prompt_color_separator_same_color 949494 +tide_prompt_min_cols 34 +tide_prompt_pad_items false +tide_prompt_transient_enabled false +tide_pulumi_bg_color normal +tide_pulumi_color F7BF2A +tide_pwd_bg_color normal +tide_pwd_color_anchors $_tide_color_light_blue +tide_pwd_color_dirs $_tide_color_dark_blue +tide_pwd_color_truncated_dirs 8787AF +tide_pwd_markers .bzr .citc .git .hg .node-version .python-version .ruby-version .shorten_folder_marker .svn .terraform Cargo.toml composer.json CVS go.mod package.json build.zig +tide_python_bg_color normal +tide_python_color 00AFAF +tide_right_prompt_frame_enabled false +tide_right_prompt_items status cmd_duration context jobs direnv node python rustc java php pulumi ruby go gcloud kubectl distrobox toolbox terraform aws nix_shell crystal elixir zig +tide_right_prompt_prefix ' ' +tide_right_prompt_separator_diff_color ' ' +tide_right_prompt_separator_same_color ' ' +tide_right_prompt_suffix '' +tide_ruby_bg_color normal +tide_ruby_color B31209 +tide_rustc_bg_color normal +tide_rustc_color F74C00 +tide_shlvl_bg_color normal +tide_shlvl_color d78700 +tide_shlvl_threshold 1 +tide_status_bg_color normal +tide_status_bg_color_failure normal +tide_status_color $_tide_color_dark_green +tide_status_color_failure D70000 +tide_terraform_bg_color normal +tide_terraform_color 844FBA +tide_time_bg_color normal +tide_time_color 5F8787 +tide_time_format %T +tide_toolbox_bg_color normal +tide_toolbox_color 613583 +tide_vi_mode_bg_color_default normal +tide_vi_mode_bg_color_insert normal +tide_vi_mode_bg_color_replace normal +tide_vi_mode_bg_color_visual normal +tide_vi_mode_color_default 949494 +tide_vi_mode_color_insert 87AFAF +tide_vi_mode_color_replace 87AF87 +tide_vi_mode_color_visual FF8700 +tide_zig_bg_color normal +tide_zig_color F7A41D diff --git a/home-config/fish/functions/tide/configure/configs/lean_16color.fish b/home-config/fish/functions/tide/configure/configs/lean_16color.fish new file mode 100644 index 0000000..16c2511 --- /dev/null +++ b/home-config/fish/functions/tide/configure/configs/lean_16color.fish @@ -0,0 +1,89 @@ +tide_aws_bg_color normal +tide_aws_color yellow +tide_character_color brgreen +tide_character_color_failure brred +tide_cmd_duration_bg_color normal +tide_cmd_duration_color brblack +tide_context_bg_color normal +tide_context_color_default yellow +tide_context_color_root bryellow +tide_context_color_ssh yellow +tide_crystal_bg_color normal +tide_crystal_color brwhite +tide_direnv_bg_color normal +tide_direnv_bg_color_denied normal +tide_direnv_color bryellow +tide_direnv_color_denied brred +tide_distrobox_bg_color normal +tide_distrobox_color brmagenta +tide_docker_bg_color normal +tide_docker_color blue +tide_elixir_bg_color normal +tide_elixir_color magenta +tide_gcloud_bg_color normal +tide_gcloud_color blue +tide_git_bg_color normal +tide_git_bg_color_unstable normal +tide_git_bg_color_urgent normal +tide_git_color_branch brgreen +tide_git_color_conflicted brred +tide_git_color_dirty bryellow +tide_git_color_operation brred +tide_git_color_staged bryellow +tide_git_color_stash brgreen +tide_git_color_untracked brblue +tide_git_color_upstream brgreen +tide_go_bg_color normal +tide_go_color brcyan +tide_java_bg_color normal +tide_java_color yellow +tide_jobs_bg_color normal +tide_jobs_color green +tide_kubectl_bg_color normal +tide_kubectl_color blue +tide_nix_shell_bg_color normal +tide_nix_shell_color brblue +tide_node_bg_color normal +tide_node_color green +tide_os_bg_color normal +tide_os_color brwhite +tide_php_bg_color normal +tide_php_color blue +tide_private_mode_bg_color normal +tide_private_mode_color brwhite +tide_prompt_color_frame_and_connection brblack +tide_prompt_color_separator_same_color brblack +tide_pulumi_bg_color normal +tide_pulumi_color yellow +tide_pwd_bg_color normal +tide_pwd_color_anchors brcyan +tide_pwd_color_dirs cyan +tide_pwd_color_truncated_dirs magenta +tide_python_bg_color normal +tide_python_color cyan +tide_ruby_bg_color normal +tide_ruby_color red +tide_rustc_bg_color normal +tide_rustc_color red +tide_shlvl_bg_color normal +tide_shlvl_color yellow +tide_status_bg_color normal +tide_status_bg_color_failure normal +tide_status_color green +tide_status_color_failure red +tide_terraform_bg_color normal +tide_terraform_color magenta +tide_time_bg_color normal +tide_time_color brblack +tide_toolbox_bg_color normal +tide_toolbox_color magenta +tide_vi_mode_bg_color_default normal +tide_vi_mode_bg_color_insert normal +tide_vi_mode_bg_color_replace normal +tide_vi_mode_bg_color_visual normal +tide_vi_mode_color_default white +tide_vi_mode_color_insert cyan +tide_vi_mode_color_replace green +tide_vi_mode_color_visual yellow +tide_zig_bg_color normal +tide_zig_color yellow diff --git a/home-config/fish/functions/tide/configure/configs/rainbow.fish b/home-config/fish/functions/tide/configure/configs/rainbow.fish new file mode 100644 index 0000000..60c1592 --- /dev/null +++ b/home-config/fish/functions/tide/configure/configs/rainbow.fish @@ -0,0 +1,116 @@ +tide_aws_bg_color FF9900 +tide_aws_color 232F3E +tide_character_color $_tide_color_green +tide_character_color_failure FF0000 +tide_cmd_duration_bg_color C4A000 +tide_cmd_duration_color 000000 +tide_cmd_duration_decimals 0 +tide_cmd_duration_threshold 3000 +tide_context_always_display false +tide_context_bg_color 444444 +tide_context_color_default D7AF87 +tide_context_color_root $_tide_color_gold +tide_context_color_ssh D7AF87 +tide_context_hostname_parts 1 +tide_crystal_bg_color FFFFFF +tide_crystal_color 000000 +tide_direnv_bg_color $_tide_color_gold +tide_direnv_bg_color_denied FF0000 +tide_direnv_color 000000 +tide_direnv_color_denied 000000 +tide_distrobox_bg_color FF00FF +tide_distrobox_color 000000 +tide_docker_bg_color 2496ED +tide_docker_color 000000 +tide_docker_default_contexts default colima +tide_elixir_bg_color 4E2A8E +tide_elixir_color 000000 +tide_gcloud_bg_color 4285F4 +tide_gcloud_color 000000 +tide_git_bg_color 4E9A06 +tide_git_bg_color_unstable C4A000 +tide_git_bg_color_urgent CC0000 +tide_git_color_branch 000000 +tide_git_color_conflicted 000000 +tide_git_color_dirty 000000 +tide_git_color_operation 000000 +tide_git_color_staged 000000 +tide_git_color_stash 000000 +tide_git_color_untracked 000000 +tide_git_color_upstream 000000 +tide_git_truncation_length 24 +tide_git_truncation_strategy +tide_go_bg_color 00ACD7 +tide_go_color 000000 +tide_java_bg_color ED8B00 +tide_java_color 000000 +tide_jobs_bg_color 444444 +tide_jobs_color 4E9A06 +tide_jobs_number_threshold 1000 +tide_kubectl_bg_color 326CE5 +tide_kubectl_color 000000 +tide_left_prompt_frame_enabled true +tide_left_prompt_items pwd git newline +tide_left_prompt_prefix '' +tide_left_prompt_separator_diff_color  +tide_left_prompt_separator_same_color  +tide_left_prompt_suffix  +tide_nix_shell_bg_color 7EBAE4 +tide_nix_shell_color 000000 +tide_node_bg_color 44883E +tide_node_color 000000 +tide_os_bg_color $os_branding_bg_color +tide_os_color $os_branding_color +tide_php_bg_color 617CBE +tide_php_color 000000 +tide_private_mode_bg_color F1F3F4 +tide_private_mode_color 000000 +tide_prompt_add_newline_before true +tide_prompt_color_frame_and_connection 6C6C6C +tide_prompt_color_separator_same_color 949494 +tide_prompt_min_cols 34 +tide_prompt_pad_items true +tide_prompt_transient_enabled false +tide_pulumi_bg_color F7BF2A +tide_pulumi_color 000000 +tide_pwd_bg_color 3465A4 +tide_pwd_color_anchors E4E4E4 +tide_pwd_color_dirs E4E4E4 +tide_pwd_color_truncated_dirs BCBCBC +tide_pwd_markers .bzr .citc .git .hg .node-version .python-version .ruby-version .shorten_folder_marker .svn .terraform Cargo.toml composer.json CVS go.mod package.json build.zig +tide_python_bg_color 444444 +tide_python_color 00AFAF +tide_right_prompt_frame_enabled true +tide_right_prompt_items status cmd_duration context jobs direnv node python rustc java php pulumi ruby go gcloud kubectl distrobox toolbox terraform aws nix_shell crystal elixir zig +tide_right_prompt_prefix  +tide_right_prompt_separator_diff_color  +tide_right_prompt_separator_same_color  +tide_right_prompt_suffix '' +tide_ruby_bg_color B31209 +tide_ruby_color 000000 +tide_rustc_bg_color F74C00 +tide_rustc_color 000000 +tide_shlvl_bg_color 808000 +tide_shlvl_color 000000 +tide_shlvl_threshold 1 +tide_status_bg_color 2E3436 +tide_status_bg_color_failure CC0000 +tide_status_color 4E9A06 +tide_status_color_failure FFFF00 +tide_terraform_bg_color 800080 +tide_terraform_color 000000 +tide_time_bg_color D3D7CF +tide_time_color 000000 +tide_time_format %T +tide_toolbox_bg_color 613583 +tide_toolbox_color 000000 +tide_vi_mode_bg_color_default 949494 +tide_vi_mode_bg_color_insert 87AFAF +tide_vi_mode_bg_color_replace 87AF87 +tide_vi_mode_bg_color_visual FF8700 +tide_vi_mode_color_default 000000 +tide_vi_mode_color_insert 000000 +tide_vi_mode_color_replace 000000 +tide_vi_mode_color_visual 000000 +tide_zig_bg_color F7A41D +tide_zig_color 000000 diff --git a/home-config/fish/functions/tide/configure/configs/rainbow_16color.fish b/home-config/fish/functions/tide/configure/configs/rainbow_16color.fish new file mode 100644 index 0000000..a040f58 --- /dev/null +++ b/home-config/fish/functions/tide/configure/configs/rainbow_16color.fish @@ -0,0 +1,93 @@ +tide_aws_bg_color yellow +tide_aws_color brblack +tide_character_color brgreen +tide_character_color_failure brred +tide_cmd_duration_bg_color yellow +tide_cmd_duration_color black +tide_context_bg_color brblack +tide_context_color_default yellow +tide_context_color_root yellow +tide_context_color_ssh yellow +tide_crystal_bg_color brwhite +tide_crystal_color black +tide_direnv_bg_color bryellow +tide_direnv_bg_color_denied brred +tide_direnv_color black +tide_direnv_color_denied black +tide_distrobox_bg_color brmagenta +tide_distrobox_color black +tide_docker_bg_color blue +tide_docker_color black +tide_elixir_bg_color magenta +tide_elixir_color black +tide_gcloud_bg_color blue +tide_gcloud_color black +tide_git_bg_color green +tide_git_bg_color_unstable yellow +tide_git_bg_color_urgent red +tide_git_color_branch black +tide_git_color_conflicted black +tide_git_color_dirty black +tide_git_color_operation black +tide_git_color_staged black +tide_git_color_stash black +tide_git_color_untracked black +tide_git_color_upstream black +tide_go_bg_color brcyan +tide_go_color black +tide_java_bg_color yellow +tide_java_color black +tide_jobs_bg_color brblack +tide_jobs_color green +tide_kubectl_bg_color blue +tide_kubectl_color black +tide_nix_shell_bg_color brblue +tide_nix_shell_color black +tide_node_bg_color green +tide_node_color black +tide_os_bg_color white +tide_os_color black +tide_php_bg_color blue +tide_php_color black +tide_private_mode_bg_color brwhite +tide_private_mode_color black +tide_prompt_color_frame_and_connection brblack +tide_prompt_color_separator_same_color brblack +tide_pulumi_bg_color yellow +tide_pulumi_color black +tide_pwd_bg_color blue +tide_pwd_color_anchors brwhite +tide_pwd_color_dirs brwhite +tide_pwd_color_truncated_dirs white +tide_python_bg_color brblack +tide_python_color cyan +tide_ruby_bg_color red +tide_ruby_color black +tide_rustc_bg_color red +tide_rustc_color black +tide_shlvl_bg_color yellow +tide_shlvl_color black +tide_status_bg_color black +tide_status_bg_color_failure red +tide_status_color green +tide_status_color_failure bryellow +tide_terraform_bg_color magenta +tide_terraform_color black +tide_time_bg_color white +tide_time_color black +tide_toolbox_bg_color magenta +tide_toolbox_color black +tide_vi_mode_bg_color_default white +tide_vi_mode_bg_color_insert cyan +tide_vi_mode_bg_color_replace green +tide_vi_mode_bg_color_visual yellow +tide_vi_mode_color_default black +tide_vi_mode_color_insert black +tide_vi_mode_color_replace black +tide_vi_mode_color_visual black +tide_vi_mode_icon_default D +tide_vi_mode_icon_insert I +tide_vi_mode_icon_replace R +tide_vi_mode_icon_visual V +tide_zig_bg_color yellow +tide_zig_color black diff --git a/home-config/fish/functions/tide/configure/functions/_fake_tide_cache_variables.fish b/home-config/fish/functions/tide/configure/functions/_fake_tide_cache_variables.fish new file mode 100644 index 0000000..4661ab1 --- /dev/null +++ b/home-config/fish/functions/tide/configure/functions/_fake_tide_cache_variables.fish @@ -0,0 +1,41 @@ +function _fake_tide_cache_variables + # pwd + set_color -o $fake_tide_pwd_color_anchors | read -gx _fake_tide_color_anchors + set -gx _fake_tide_color_truncated_dirs "$(set_color $fake_tide_pwd_color_truncated_dirs)" + set -gx _fake_tide_reset_to_color_dirs (set_color normal -b $fake_tide_pwd_bg_color; set_color $fake_tide_pwd_color_dirs) + + # git + contains git $fake_tide_left_prompt_items $fake_tide_right_prompt_items && + set -gx _fake_tide_location_color "$(set_color $fake_tide_git_color_branch)" + + # private_mode + if contains private_mode $fake_tide_left_prompt_items $fake_tide_right_prompt_items && test -n "$fish_private_mode" + set -gx _fake_tide_private_mode + else + set -e _fake_tide_private_mode + end + + # Same-color-separator color + set -gx _fake_tide_color_separator_same_color "$(set_color $fake_tide_prompt_color_separator_same_color)" + + # two line prompt + if contains newline $fake_tide_left_prompt_items + set_color $fake_tide_prompt_color_frame_and_connection -b normal | read -gx _fake_tide_prompt_and_frame_color + else + set -e _fake_tide_prompt_and_frame_color + end + + # newline before + if test "$fake_tide_prompt_add_newline_before" = true + set -g _fake_tide_add_newline '' + else + set -e _fake_tide_add_newline + end + + # item padding + if test "$fake_tide_prompt_pad_items" = true + set -gx _fake_tide_pad ' ' + else + set -e _fake_tide_pad + end +end diff --git a/home-config/fish/functions/tide/configure/functions/_fake_tide_item_character.fish b/home-config/fish/functions/tide/configure/functions/_fake_tide_item_character.fish new file mode 100644 index 0000000..94892ec --- /dev/null +++ b/home-config/fish/functions/tide/configure/functions/_fake_tide_item_character.fish @@ -0,0 +1,8 @@ +function _fake_tide_item_character + set_color $fake_tide_character_color + if contains newline $fake_tide_left_prompt_items || set -q _configure_transient + echo -ns $fake_tide_character_icon + else + echo -ns ' '$fake_tide_character_icon + end +end diff --git a/home-config/fish/functions/tide/configure/functions/_fake_tide_item_cmd_duration.fish b/home-config/fish/functions/tide/configure/functions/_fake_tide_item_cmd_duration.fish new file mode 100644 index 0000000..5aa13b2 --- /dev/null +++ b/home-config/fish/functions/tide/configure/functions/_fake_tide_item_cmd_duration.fish @@ -0,0 +1,3 @@ +function _fake_tide_item_cmd_duration + _fake_tide_print_item cmd_duration $fake_tide_cmd_duration_icon' ' 5s +end diff --git a/home-config/fish/functions/tide/configure/functions/_fake_tide_item_git.fish b/home-config/fish/functions/tide/configure/functions/_fake_tide_item_git.fish new file mode 100644 index 0000000..fb5b957 --- /dev/null +++ b/home-config/fish/functions/tide/configure/functions/_fake_tide_item_git.fish @@ -0,0 +1,3 @@ +function _fake_tide_item_git + _fake_tide_print_item git (set_color $fake_tide_git_color_branch) $fake_tide_git_icon' ' main +end diff --git a/home-config/fish/functions/tide/configure/functions/_fake_tide_item_newline.fish b/home-config/fish/functions/tide/configure/functions/_fake_tide_item_newline.fish new file mode 100644 index 0000000..c614bab --- /dev/null +++ b/home-config/fish/functions/tide/configure/functions/_fake_tide_item_newline.fish @@ -0,0 +1,5 @@ +function _fake_tide_item_newline + set_color $prev_bg_color -b normal + var=fake_tide_"$_fake_tide_side"_prompt_suffix echo $$var + set -g add_prefix +end diff --git a/home-config/fish/functions/tide/configure/functions/_fake_tide_item_os.fish b/home-config/fish/functions/tide/configure/functions/_fake_tide_item_os.fish new file mode 100644 index 0000000..5255721 --- /dev/null +++ b/home-config/fish/functions/tide/configure/functions/_fake_tide_item_os.fish @@ -0,0 +1,3 @@ +function _fake_tide_item_os + _fake_tide_print_item os $fake_tide_os_icon +end diff --git a/home-config/fish/functions/tide/configure/functions/_fake_tide_item_time.fish b/home-config/fish/functions/tide/configure/functions/_fake_tide_item_time.fish new file mode 100644 index 0000000..bbce0b5 --- /dev/null +++ b/home-config/fish/functions/tide/configure/functions/_fake_tide_item_time.fish @@ -0,0 +1,3 @@ +function _fake_tide_item_time + _fake_tide_print_item time (date +$fake_tide_time_format) +end diff --git a/home-config/fish/functions/tide/configure/functions/_fake_tide_print_item.fish b/home-config/fish/functions/tide/configure/functions/_fake_tide_print_item.fish new file mode 100644 index 0000000..30cd024 --- /dev/null +++ b/home-config/fish/functions/tide/configure/functions/_fake_tide_print_item.fish @@ -0,0 +1,22 @@ +function _fake_tide_print_item -a item + var=fake_tide_"$item"_bg_color set -f item_bg_color $$var + + if set -e add_prefix + set_color $item_bg_color -b normal + var=fake_tide_"$_fake_tide_side"_prompt_prefix echo -ns $$var + else if test "$item_bg_color" = "$prev_bg_color" + var=fake_tide_"$_fake_tide_side"_prompt_separator_same_color echo -ns $_fake_tide_color_separator_same_color$$var + else if test "$_fake_tide_side" = left + set_color $prev_bg_color -b $item_bg_color + echo -ns $fake_tide_left_prompt_separator_diff_color + else + set_color $item_bg_color -b $prev_bg_color + echo -ns $fake_tide_right_prompt_separator_diff_color + end + + var=fake_tide_"$item"_color set_color $$var -b $item_bg_color + + echo -ns $_fake_tide_pad $argv[2..] $_fake_tide_pad + + set -g prev_bg_color $item_bg_color +end diff --git a/home-config/fish/functions/tide/configure/functions/_fake_tide_prompt.fish b/home-config/fish/functions/tide/configure/functions/_fake_tide_prompt.fish new file mode 100644 index 0000000..11f20ca --- /dev/null +++ b/home-config/fish/functions/tide/configure/functions/_fake_tide_prompt.fish @@ -0,0 +1,42 @@ +function _fake_tide_prompt + set -g add_prefix + _fake_tide_side=left set -f left (for item in $fake_tide_left_prompt_items + _fake_tide_item_$item + end + if not set -e add_prefix + set_color $prev_bg_color -b normal + echo -ns $fake_tide_left_prompt_suffix + end) + + set -g add_prefix + _fake_tide_side=right set -f right (for item in $fake_tide_right_prompt_items + _fake_tide_item_$item + end + if not set -e add_prefix + set_color $prev_bg_color -b normal + echo -ns $fake_tide_right_prompt_suffix + end) + + if set -q _fake_tide_prompt_and_frame_color # If prompt is two lines + test "$fake_tide_left_prompt_frame_enabled" = true && + set left[1] "$_fake_tide_prompt_and_frame_color╭─$left[1]" && + set left[2] "$_fake_tide_prompt_and_frame_color╰─$left[2]" + test "$fake_tide_right_prompt_frame_enabled" = true && + set right[1] "$right[1]$_fake_tide_prompt_and_frame_color─╮" && + set right[2] "$right[2]$_fake_tide_prompt_and_frame_color─╯" + + # 5 = @PWD@ length which will be replaced + math $fake_columns+5-(string length --visible "$left[1]$right[1]") | read -lx dist_btwn_sides + echo -ns "$right[2]"\n(string replace @PWD@ (_fake_tide_pwd) "$left[1]")$_fake_tide_prompt_and_frame_color + + string repeat --no-newline --max (math max 0, $dist_btwn_sides-$_tide_pwd_len) $fake_tide_prompt_icon_connection + echo -ns "$right[1]"\n"$left[2] " + else + math $fake_columns+5-(string length --visible "$left[1]$right[1]") -$fake_tide_prompt_min_cols | read -lx dist_btwn_sides + string replace @PWD@ (_fake_tide_pwd) "$right[1]" "$left[1] " + end +end + +function _fake_tide_item_pwd + _fake_tide_print_item pwd @PWD@ +end diff --git a/home-config/fish/functions/tide/configure/functions/_fake_tide_pwd.fish b/home-config/fish/functions/tide/configure/functions/_fake_tide_pwd.fish new file mode 100644 index 0000000..433eafa --- /dev/null +++ b/home-config/fish/functions/tide/configure/functions/_fake_tide_pwd.fish @@ -0,0 +1,11 @@ +function _fake_tide_pwd + set -l out ( + set_color $fake_tide_pwd_color_dirs + echo -ns $fake_tide_pwd_icon' ' '~/' + set_color -o $fake_tide_pwd_color_anchors + echo -ns src + set_color normal -b $fake_tide_pwd_bg_color + ) + set -g _tide_pwd_len (string length --visible $out) + echo -ns $out +end diff --git a/home-config/fish/functions/tide/configure/icons.fish b/home-config/fish/functions/tide/configure/icons.fish new file mode 100644 index 0000000..70611cd --- /dev/null +++ b/home-config/fish/functions/tide/configure/icons.fish @@ -0,0 +1,40 @@ +tide_aws_icon  # Actual aws glyph is harder to see +tide_character_icon ❯ +tide_character_vi_icon_default ❮ +tide_character_vi_icon_replace ▶ +tide_character_vi_icon_visual V +tide_cmd_duration_icon +tide_crystal_icon  +tide_direnv_icon ▼ +tide_distrobox_icon 󰆧 +tide_docker_icon  +tide_elixir_icon  +tide_gcloud_icon 󰊭 # Actual google cloud glyph is harder to see +tide_git_icon +tide_go_icon  +tide_java_icon  +tide_jobs_icon  +tide_kubectl_icon 󱃾 +tide_nix_shell_icon  +tide_node_icon  # Actual nodejs glyph is harder to see +tide_os_icon $os_branding_icon +tide_php_icon  +tide_private_mode_icon 󰗹 +tide_prompt_icon_connection ' ' +tide_pulumi_icon  +tide_pwd_icon +tide_pwd_icon_home +tide_pwd_icon_unwritable  +tide_python_icon 󰌠 +tide_ruby_icon  +tide_rustc_icon  +tide_shlvl_icon  +tide_status_icon ✔ +tide_status_icon_failure ✘ +tide_terraform_icon 󱁢 +tide_toolbox_icon  +tide_vi_mode_icon_default D +tide_vi_mode_icon_insert I +tide_vi_mode_icon_replace R +tide_vi_mode_icon_visual V +tide_zig_icon  -- cgit v1.2.3