From: Philippe Proulx Date: Thu, 26 Oct 2023 12:45:45 +0000 (-0400) Subject: tools/format-cpp: add `-t` to `xargs` X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=commitdiff_plain;h=0ea5233cb503cbcdb27026b96f536fd5d39213ba tools/format-cpp: add `-t` to `xargs` `tools/format-cpp` can be a bit long, so show the progress by making xargs print the executed command. Signed-off-by: Philippe Proulx Change-Id: Ifb5e40017a2bb429ce7e900a2076532bc038a792 Reviewed-on: https://review.lttng.org/c/babeltrace/+/11143 Reviewed-by: Michael Jeanson --- diff --git a/tools/format-cpp b/tools/format-cpp index a2c6a3ae..29a0bf7e 100755 --- a/tools/format-cpp +++ b/tools/format-cpp @@ -35,7 +35,7 @@ format_cpp() { ! -wholename '*/cpp-common/optional.hpp' \ ! -wholename '*/cpp-common/string_view.hpp' \ ! -wholename '*/cpp-common/nlohmann/json.hpp' \ - -print0 | xargs -P"$(nproc)" -n1 -0 "${formatter[@]}" + -print0 | xargs -P"$(nproc)" -n1 -t -0 "${formatter[@]}" } if [[ -n "$FORMATTER" ]]; then