mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-29 06:13:20 +00:00
de47a096e8
[ci skip]
6 lines
201 B
Fish
6 lines
201 B
Fish
function __fish_is_nth_token
|
|
set -l n $argv[1]
|
|
set -l tokens (commandline -poc)
|
|
set -l tokens (string replace -r --filter '^([^-].*)' '$1' -- $tokens)
|
|
test (count $tokens) -eq "$n"
|
|
end
|