There is nothing specific in the rust port that makes fish more available for servers or LTS distros.
Being written in Rust does improve availability, because by default Rust statically links against everything except libc and the Rust standard library, and you can opt out of those if necessary. So there is inherently no need to build separate dependency packages for each distro, unless you use a Rust crate that specifically links to a C or C++ library.
fish links against pcre2, which is a C library (via the pcre2 crate).
(it used to also link against ncurses, now it uses the terminfo crate instead, which just reads the terminfo database in rust)
Of course there is a way to make fish distributable as almost a single file (https://github.com/fish-shell/fish-shell/pull/10367), which rust does make easier (rust-embed is frickin’ cool), but these sorts of shenanigans would also be possible with C++ and aren’t really a big driver of the rust port. It’s more that cargo install would try to install it like that and so why not make that work?
Really, my issue here is that the article makes “making fish available on servers” this huge deal when fish has always been available on servers?
Oh, right, yes; of course it statically links the standard library. I was thinking of the fact that the standard lib is precompiled, but yes, it’s statically linked.
Being written in Rust does improve availability, because by default Rust statically links against everything except libc and the Rust standard library, and you can opt out of those if necessary. So there is inherently no need to build separate dependency packages for each distro, unless you use a Rust crate that specifically links to a C or C++ library.
fish links against pcre2, which is a C library (via the pcre2 crate).
(it used to also link against ncurses, now it uses the terminfo crate instead, which just reads the terminfo database in rust)
Of course there is a way to make fish distributable as almost a single file (https://github.com/fish-shell/fish-shell/pull/10367), which rust does make easier (rust-embed is frickin’ cool), but these sorts of shenanigans would also be possible with C++ and aren’t really a big driver of the rust port. It’s more that
cargo install
would try to install it like that and so why not make that work?Really, my issue here is that the article makes “making fish available on servers” this huge deal when fish has always been available on servers?
It actually statically links the Rust standard library too. You can also avoid glibc by using musl with a one line change.
Oh, right, yes; of course it statically links the standard library. I was thinking of the fact that the standard lib is precompiled, but yes, it’s statically linked.