|
| From: | Peng Yu |
| Subject: | Re: Is there a way to get the output of a function without an extra bash process? |
| Date: | Sun, 10 May 2020 16:53:43 -0500 |
> Have you tried this:
>
> $ cat ./main2.sh
> #!/usr/bin/env bash
> # vim: set noexpandtab tabstop=2:
>
> set -v
> echo "$BASHPID"
> function f {
> echo "$BASHPID"
> }
> f
> $
The output of f must be saved in a bash variable.
--
Regards,
Peng
| [Prev in Thread] | Current Thread | [Next in Thread] |