Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use path basename in preference to basename #143

Merged
merged 1 commit into from
Nov 21, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions functions/pond.fish
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ Usage:
set -l pond_matches

for pond_path in $pond_home/*
set -l pond_short_name (basename $pond_path)
set -l pond_short_name (path basename $pond_path)

if test "$pond_list_enabled" = yes
if contains $pond_path $pond_function_path
Expand Down Expand Up @@ -415,17 +415,17 @@ Usage:
if test (count $pond_dirs) -gt 0
for pond_dir in $pond_dirs[..-2]
if contains (string sub -e -1 $pond_dir) $fish_function_path
echo $pond_load_padding├─(set_color green)$pond_load_indicator(set_color normal) (basename $pond_dir)
echo $pond_load_padding├─(set_color green)$pond_load_indicator(set_color normal) (path basename $pond_dir)
else
echo $pond_load_padding├─(set_color 8a8a8a brblack)$pond_load_indicator (basename $pond_dir)(set_color normal)
echo $pond_load_padding├─(set_color 8a8a8a brblack)$pond_load_indicator (path basename $pond_dir)(set_color normal)
end
end

for pond_dir in $pond_dirs[-1]
if contains (string sub -e -1 $pond_dirs[-1]) $fish_function_path
echo $pond_load_padding└─(set_color green)$pond_load_indicator(set_color normal) (basename $pond_dirs[-1])
echo $pond_load_padding└─(set_color green)$pond_load_indicator(set_color normal) (path basename $pond_dirs[-1])
else
echo $pond_load_padding└─(set_color 8a8a8a brblack)$pond_load_indicator (basename $pond_dirs[-1])(set_color normal)
echo $pond_load_padding└─(set_color 8a8a8a brblack)$pond_load_indicator (path basename $pond_dirs[-1])(set_color normal)
end
end
else
Expand Down Expand Up @@ -479,7 +479,7 @@ Usage:
set failures (math $failures + 1)
end

echo " "(basename $pond_function)
echo " "(path basename $pond_function)
end

set -l total (math $passes + $failures)
Expand Down