summaryrefslogtreecommitdiffstats
path: root/scripts/libptxdist.sh
diff options
context:
space:
mode:
authorMichael Olbrich <m.olbrich@pengutronix.de>2019-10-27 19:31:03 +0100
committerMichael Olbrich <m.olbrich@pengutronix.de>2019-10-29 09:54:24 +0100
commitd034477464c1e6dea4f6c321b0643ed1f08d2710 (patch)
tree40f181a14cfe51ee5238ff8ed5f3aa59046a370a /scripts/libptxdist.sh
parent7c81ecf70866ad9fb6b5d075440eea222ce20ae4 (diff)
downloadptxdist-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.sh10
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() {