Skip to content

Commit

Permalink
fix(envman): split non-portable function.env => function.sh, function…
Browse files Browse the repository at this point in the history
….fish
  • Loading branch information
coolaj86 committed Nov 22, 2023
1 parent 0da4b5d commit 4510a61
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions _webi/package-install.tpl.sh
Original file line number Diff line number Diff line change
Expand Up @@ -853,7 +853,7 @@ fn_envman_init_load_sh() { (
touch -a ~/.config/envman/PATH.env
touch -a ~/.config/envman/ENV.env
touch -a ~/.config/envman/alias.env
touch -a ~/.config/envman/function.env
touch -a ~/.config/envman/function.sh
# ENV first because we may use it in PATH
test -z "\${ENVMAN_LOAD:-}" && . ~/.config/envman/ENV.env
Expand All @@ -862,7 +862,7 @@ test -z "\${ENVMAN_LOAD:-}" && . ~/.config/envman/PATH.env
export ENVMAN_LOAD='loaded'
# function first because we may use it in alias
test -z "\${g_envman_load_sh:-}" && . ~/.config/envman/function.env
test -z "\${g_envman_load_sh:-}" && . ~/.config/envman/function.sh
test -z "\${g_envman_load_sh:-}" && . ~/.config/envman/alias.env
g_envman_load_sh='loaded'
Expand Down Expand Up @@ -918,14 +918,14 @@ fn_envman_init_load_fish() { (
touch -a ~/.config/envman/PATH.env
touch -a ~/.config/envman/ENV.env
touch -a ~/.config/envman/alias.env
touch -a ~/.config/envman/function.env
touch -a ~/.config/envman/function.fish
not set -q ENVMAN_LOAD; and source ~/.config/envman/ENV.env
not set -q ENVMAN_LOAD; and source ~/.config/envman/PATH.env
set -x ENVMAN_LOAD 'loaded'
not set -q g_envman_load_fish; and source ~/.config/envman/function.env
not set -q g_envman_load_fish; and source ~/.config/envman/function.fish
not set -q g_envman_load_fish; and source ~/.config/envman/alias.env
set -g g_envman_load_fish 'loaded'
Expand Down

0 comments on commit 4510a61

Please sign in to comment.