Loading pkgs/shells/fish-foreign-env/default.nix +4 −2 Original line number Diff line number Diff line Loading @@ -11,15 +11,17 @@ stdenv.mkDerivation rec { sha256 = "0lwp6hy3kfk7xfx4xvbk1ir8zkzm7gfjbm4bf6xg1y6iw9jq9dnl"; }; buildCommand = '' installPhase = '' mkdir -p $out/share/fish-foreign-env/functions/ cp $src/functions/* $out/share/fish-foreign-env/functions/ cp functions/* $out/share/fish-foreign-env/functions/ sed -e "s|sed|${gnused}/bin/sed|" \ -e "s|bash|${bash}/bin/bash|" \ -e "s|\| tr|\| ${coreutils}/bin/tr|" \ -i $out/share/fish-foreign-env/functions/* ''; patches = [ ./hide-path-warnings.patch ]; meta = with stdenv.lib; { description = "A foreign environment interface for Fish shell"; license = licenses.mit; Loading pkgs/shells/fish-foreign-env/hide-path-warnings.patch 0 → 100644 +16 −0 Original line number Diff line number Diff line diff --git a/functions/fenv.apply.fish b/functions/fenv.apply.fish index 34a25e3..6837e7f 100644 --- a/functions/fenv.apply.fish +++ b/functions/fenv.apply.fish @@ -30,8 +30,9 @@ function fenv.apply if test "$key" = 'PATH' set value (echo $value | tr ':' '\n') + set -g -x $key $value ^/dev/null + else + set -g -x $key $value end - - set -g -x $key $value end end Loading
pkgs/shells/fish-foreign-env/default.nix +4 −2 Original line number Diff line number Diff line Loading @@ -11,15 +11,17 @@ stdenv.mkDerivation rec { sha256 = "0lwp6hy3kfk7xfx4xvbk1ir8zkzm7gfjbm4bf6xg1y6iw9jq9dnl"; }; buildCommand = '' installPhase = '' mkdir -p $out/share/fish-foreign-env/functions/ cp $src/functions/* $out/share/fish-foreign-env/functions/ cp functions/* $out/share/fish-foreign-env/functions/ sed -e "s|sed|${gnused}/bin/sed|" \ -e "s|bash|${bash}/bin/bash|" \ -e "s|\| tr|\| ${coreutils}/bin/tr|" \ -i $out/share/fish-foreign-env/functions/* ''; patches = [ ./hide-path-warnings.patch ]; meta = with stdenv.lib; { description = "A foreign environment interface for Fish shell"; license = licenses.mit; Loading
pkgs/shells/fish-foreign-env/hide-path-warnings.patch 0 → 100644 +16 −0 Original line number Diff line number Diff line diff --git a/functions/fenv.apply.fish b/functions/fenv.apply.fish index 34a25e3..6837e7f 100644 --- a/functions/fenv.apply.fish +++ b/functions/fenv.apply.fish @@ -30,8 +30,9 @@ function fenv.apply if test "$key" = 'PATH' set value (echo $value | tr ':' '\n') + set -g -x $key $value ^/dev/null + else + set -g -x $key $value end - - set -g -x $key $value end end