mirror of
https://github.com/fish-shell/fish-shell
synced 2025-01-14 05:53:59 +00:00
Revert "Add hash
function for compatibility with sh/bash"
This reverts commit dbd228cc75
.
This commit is contained in:
parent
f5083d7bab
commit
f15dd314e0
2 changed files with 0 additions and 11 deletions
|
@ -68,7 +68,6 @@ fish 3.0 is a major release which brings with it both improvements in functional
|
|||
- `test` and `[` now support floating point values in numeric comparisons.
|
||||
- Autosuggestions try to avoid arguments that are already present in the command line.
|
||||
- Variables may be used inside commands (#154).
|
||||
- A `hash` function has been added for compatibiility with `sh` and `bash`
|
||||
- `while` sets `$status` to a more useful value (#4982)
|
||||
|
||||
## Other significant changes
|
||||
|
|
|
@ -1,10 +0,0 @@
|
|||
# Under (ba)sh, `hash` acts like a caching `which`, but it doesn't print
|
||||
# anything on success. Its return code is used to determine success vs failure.
|
||||
function hash
|
||||
if not set -q argv[1]
|
||||
echo "Usage: hash FILE" >&2
|
||||
return 1
|
||||
end
|
||||
which $argv[1] 2>/dev/null 1>/dev/null
|
||||
or printf "%s: not found!\n" $argv[1] >&2 && return 2 # ENOENT
|
||||
end
|
Loading…
Reference in a new issue