Files
fish-shell/share/functions/__fish_uname.fish
Johannes Altmanninger 49023adec7 Consolidate some calls to uname(1) around shell startup
Most versions of fish don't run any external processes at startup, except
maybe fish_vcs_prompt.  This changed recently with a couple additions of uname.
This is probably fine but I guess we can reduce it down to one.

This change feels somewhat wrong. Not sure.  I guess we can remove it once
we provide $OSTYPE.

Note that this is also the reason why bindings don't use

	bind alt-backspace 'if test "$(uname)" = Darwin ...'

We don't want to expose a private interface in "bind" output.
2025-03-05 12:34:17 +01:00

7 lines
127 B
Fish

function __fish_uname
if not set -q __fish_uname
set -g __fish_uname (uname)
end
echo -- $__fish_uname
end