diff options
author | Michael Olbrich <m.olbrich@pengutronix.de> | 2019-10-27 19:31:03 +0100 |
---|---|---|
committer | Michael Olbrich <m.olbrich@pengutronix.de> | 2019-10-29 09:54:24 +0100 |
commit | d034477464c1e6dea4f6c321b0643ed1f08d2710 (patch) | |
tree | 40f181a14cfe51ee5238ff8ed5f3aa59046a370a /scripts/libptxdist.sh | |
parent | 7c81ecf70866ad9fb6b5d075440eea222ce20ae4 (diff) | |
download | ptxdist-d034477464c1e6dea4f6c321b0643ed1f08d2710.tar.gz ptxdist-d034477464c1e6dea4f6c321b0643ed1f08d2710.tar.xz |
libptxdist: add new function ptxd_exec
It is very similar to ptxd_eval but it runs the command directly instead of
using eval. It is useful to allow printing complex commands when using
'--verbose'.
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
Diffstat (limited to 'scripts/libptxdist.sh')
-rw-r--r-- | scripts/libptxdist.sh | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/scripts/libptxdist.sh b/scripts/libptxdist.sh index 8c6fbc073..df123980c 100644 --- a/scripts/libptxdist.sh +++ b/scripts/libptxdist.sh @@ -759,6 +759,16 @@ ptxd_eval() { export -f ptxd_eval # +# execute the arguments +# +ptxd_exec() { + ptxd_verbose "executing:" "${@} +" + "${@}" +} +export -f ptxd_exec + +# # check if a previously executed pipe returned an error # check_pipe_status() { |