helpers/envkernel.sh: return 0 from fish_compat if --fish is not present (MR 2221)

Right now this returns 1 when envkernel.sh is sourced for some reason. I
don't understand why exactly, but this seems like a sensible solution to
me.

Closes https://gitlab.com/postmarketOS/pmbootstrap/-/issues/2133
This commit is contained in:
Newbyte 2022-10-24 15:31:30 +02:00 committed by Oliver Smith
parent 2ca4518799
commit 8770aba287
No known key found for this signature in database
GPG Key ID: 5AE7F5513E0885CB
1 changed files with 1 additions and 1 deletions

View File

@ -405,7 +405,7 @@ main() {
# Print fish alias syntax (when called from envkernel.fish)
fish_compat() {
[ "$1" = "--fish" ] || return
[ "$1" = "--fish" ] || return 0
for name in make kernelroot pmbootstrap pmbroot; do
echo "alias $(alias $name | sed 's/=/ /')"
done