Skip to contentSkip to conversation

utils/docker-run: hide docker run command

Buildroot Yann E. MORIN 1 participant 1 message Feb 16, 2022

lore
Share & tools
lore
#0 lore raw

commit: https://git.buildroot.net/buildroot/commit/?id=cc9470c2d8134106792a5a0179fbd0c6ca4d37af
branch: https://git.buildroot.net/buildroot/commit/?id=refs/heads/master

Since this is a helper script there is not much reason to show the command that's been issued. Furthermore, the incantation has been slightly extended since the script was introduced.

The only interesting reason to print the command is to know what image it is being spawned into. However, this is prominently displayed by docker the first time the script is run, as it can't find the image locally and has to fetch it first. Afterwards, users can still use 'docker image ls' to see what images they have locally.

So let's remove 'set -x' before running docker.

[[email protected]: reword and expand commit log]
---
 utils/docker-run | 1 -
 1 file changed, 1 deletion(-)
utils/docker-run +0 -1
index bdbc979264..5653764254 100755
@@ -6,7 +6,6 @@ MAIN_DIR=$(readlink -f "${DIR}/..")
 IMAGE=$(grep ^image: "${MAIN_DIR}/.gitlab-ci.yml" | \
         sed -e 's,^image: ,,g' | sed -e 's,\$CI_REGISTRY,registry.gitlab.com,g')
 
-set -x
 exec docker run -it --rm \
     --user $(id -u):$(id -g) \
     --mount "type=bind,src=${MAIN_DIR},dst=${MAIN_DIR}" \

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot