diff options
author | Fabian Homborg <FHomborg@gmail.com> | 2015-11-27 19:34:27 +0100 |
---|---|---|
committer | Fabian Homborg <FHomborg@gmail.com> | 2015-11-27 19:34:27 +0100 |
commit | 53fc9a4002494e2b1dd7d89f4c62398b64b96059 (patch) | |
tree | 710acf6380a262c92fe48ff878300e9f5185f581 /share | |
parent | a8a9ac0dae54bc83399f5354e8d11aacba6779ff (diff) |
Remove circular dependency in fallback seq
This was subtle because `type` invoked seq.
Fixes #2570
Diffstat (limited to 'share')
-rw-r--r-- | share/functions/seq.fish | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/share/functions/seq.fish b/share/functions/seq.fish index 4229f0c5..3675c990 100644 --- a/share/functions/seq.fish +++ b/share/functions/seq.fish @@ -1,8 +1,7 @@ # If seq is not installed, then define a function that invokes __fish_fallback_seq -# test -x in /usr/bin/seq because that's where it usually is and -# that's substantially cheaper than the type function +# We can't call type here because that also calls seq -if begin ; not test -x /usr/bin/seq ; and not type -q -f seq; end +if not command -s seq >/dev/null # No seq command function seq --description "Print sequences of numbers" __fish_fallback_seq $argv |