fix __fish_list_current_token not recognizing ~ as $HOME (#9954)

* fix __fish_list_current_token not recognizing ~ as $HOME

* right. it was supposed to be $HOME. lol.
This commit is contained in:
Axlefublr 2023-08-17 04:05:59 +08:00 committed by GitHub
parent 1166424eeb
commit fd68aca6ea
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2,7 +2,7 @@
# of the directory under the cursor.
function __fish_list_current_token -d "List contents of token under the cursor if it is a directory, otherwise list the contents of the current directory"
set -l val (commandline -t)
set -l val (commandline -t | string replace -r '^~' "$HOME")
printf "\n"
if test -d $val
ls $val