mirror of
https://github.com/IlanCosman/tide.git
synced 2024-09-11 09:05:37 +03:00
Glob only for dirs
This commit is contained in:
parent
1b2c9d6093
commit
69c3c24e3c
@ -28,8 +28,8 @@ eval "function _tide_pwd
|
||||
set -l trunc
|
||||
string match -qr \"(?<trunc>\..|.)\" \$dir_section
|
||||
|
||||
set -l glob \$parent_dir/\$trunc*
|
||||
set -e glob[(contains -i \$parent_dir/\$dir_section \$glob)] # This is faster than inverse string match
|
||||
set -l glob \$parent_dir/\$trunc*/
|
||||
set -e glob[(contains -i \$parent_dir/\$dir_section/ \$glob)] # This is faster than inverse string match
|
||||
|
||||
while string match -qr \"^\$parent_dir/\$trunc\" \$glob && string match -qr \"(?<trunc>\$trunc.)\" \$dir_section
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user