armbian-build/lib
Ricardo Pardini da062debdd
[PR] multiple fixes for the eval + PIPESTATUS construct (#3280)
- try this on your bash shell:
  - `ONEVAR="testing" eval 'bash -c "echo value once $ONEVAR && false && echo value twice $ONEVAR"' '| grep value'  '| grep value' ; echo ${PIPESTATUS[*]}`
  - Notice how PIPESTATUS has only one element. and it is always true, although we failed explicitly with false in the middle of the bash.
  - That is because eval itself is considered a single command, no matter how many pipes you put in there, you'll get a single value, the return code of the LAST pipe.
  - Lets export the value of the pipe inside eval so we know outside what happened:
  - `ONEVAR="testing" eval 'bash -e -c "echo value once $ONEVAR && false && echo value twice $ONEVAR"' '| grep value'  '| grep value' ';EVALPIPE=(${PIPESTATUS[@]})' ; echo ${EVALPIPE[*]}`
- also: pass LC_ALL=C LANG=C to avoid locale warnings

Signed-off-by: Ricardo Pardini <ricardo@pardini.net>
2021-12-07 20:10:47 +01:00
..
build-all-ng.sh extensions framework + UEFI aarch64/x86 + rpi4b + core changes/fixes (#3300) 2021-12-06 09:49:49 +01:00
chroot-buildpackages.sh Chroot build packages cleanup and bug fixing (#3266) 2021-11-17 19:35:32 +01:00
compilation-prepare.sh extensions framework + UEFI aarch64/x86 + rpi4b + core changes/fixes (#3300) 2021-12-06 09:49:49 +01:00
compilation.sh [PR] multiple fixes for the eval + PIPESTATUS construct (#3280) 2021-12-07 20:10:47 +01:00
configuration.sh extensions framework + UEFI aarch64/x86 + rpi4b + core changes/fixes (#3300) 2021-12-06 09:49:49 +01:00
debootstrap.sh [PR] multiple fixes for the eval + PIPESTATUS construct (#3280) 2021-12-07 20:10:47 +01:00
desktop.sh A day of building and finding troubles in desktop builds (#3259) 2021-11-15 23:30:07 +01:00
distributions.sh Two small bug fixes 2021-12-06 15:55:16 +01:00
extensions.sh extensions framework + UEFI aarch64/x86 + rpi4b + core changes/fixes (#3300) 2021-12-06 09:49:49 +01:00
fel-load.sh Shellcheck fixes (#2034) 2020-06-18 10:06:21 -04:00
general.sh Add package needed to satisfy CONFIG_DEBUG_INFO_BTF. (#3299) 2021-12-06 15:57:07 +01:00
image-helpers.sh extensions framework + UEFI aarch64/x86 + rpi4b + core changes/fixes (#3300) 2021-12-06 09:49:49 +01:00
main.sh extensions framework + UEFI aarch64/x86 + rpi4b + core changes/fixes (#3300) 2021-12-06 09:49:49 +01:00
makeboarddeb.sh extensions framework + UEFI aarch64/x86 + rpi4b + core changes/fixes (#3300) 2021-12-06 09:49:49 +01:00