It looks like fenv source foo.sh will attempt to run bar in a subshell rather than interpret it literally:
⋊> fenv source foo.sh 11:20:38
fish: Unknown command 'bar'
- (line 1): bar
^
in command substitution
called on line -1 of file -
from sourcing file -
called on line 60 of file /usr/local/Cellar/fish/2.2.0/share/fish/functions/eval.fish
in function 'eval'
called on line 37 of file ~/.local/share/omf/pkg/foreign-env/fenv.apply.fish
in function 'fenv.apply'
called on line 43 of file ~/.local/share/omf/pkg/foreign-env/fenv.main.fish
with parameter list 'FOO=(bar)'
in function 'fenv.main'
called on line 26 of file ~/.local/share/omf/pkg/foreign-env/fenv.fish
with parameter list 'source foo.sh'
in function 'fenv'
called on standard input
with parameter list 'source foo.sh'
Is it possible to get fenv to handle this without having to work around it in foo.sh?
Given foo.sh:
It looks like
fenv source foo.sh
will attempt to runbar
in a subshell rather than interpret it literally:Is it possible to get fenv to handle this without having to work around it in
foo.sh
?