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/show_time.fish | 33 ++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 home-config/fish/functions/tide/configure/choices/all/show_time.fish (limited to 'home-config/fish/functions/tide/configure/choices/all/show_time.fish') 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 -- cgit v1.2.3