From 66db6c4a10569df0abf199bcb775c6ed31d7e05a Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Tue, 16 Apr 2024 23:54:08 +0200 Subject: [PATCH 1/4] dmaketgz: compacter Follow-up to d28f74913c2 Proposed-by: Viktor Szakats --- scripts/dmaketgz | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/scripts/dmaketgz b/scripts/dmaketgz index e361d35b778a3f..7e7fd0c947b0ac 100755 --- a/scripts/dmaketgz +++ b/scripts/dmaketgz @@ -39,14 +39,9 @@ docker build \ --build-arg GID="$(id -g)" \ -t curl/curl . -run="run --rm -it -u $(id -u):$(id -g) -v $(pwd):/usr/src -w /usr/src curl/curl" - -# shellcheck disable=SC2086 -# "Double quote to prevent globbing and word splitting" on the $run use below -docker $run autoreconf -fi -# shellcheck disable=SC2086 -docker $run ./configure --without-ssl --without-libpsl -# shellcheck disable=SC2086 -docker $run make -sj8 -# shellcheck disable=SC2086 -docker $run ./maketgz $version +docker run --rm -it -u $(id -u):$(id -g) -v $(pwd):/usr/src -w /usr/src curl/curl sh -c " + set -e + autoreconf -fi + ./configure --without-ssl --without-libpsl + make -sj8 + ./maketgz $version" From acedaedffb892145a7cebfd52701203eacc1e2b4 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Tue, 16 Apr 2024 23:56:18 +0200 Subject: [PATCH 2/4] shellchecked --- scripts/dmaketgz | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/dmaketgz b/scripts/dmaketgz index 7e7fd0c947b0ac..afdd4e66f3cbbb 100755 --- a/scripts/dmaketgz +++ b/scripts/dmaketgz @@ -39,7 +39,8 @@ docker build \ --build-arg GID="$(id -g)" \ -t curl/curl . -docker run --rm -it -u $(id -u):$(id -g) -v $(pwd):/usr/src -w /usr/src curl/curl sh -c " +docker run --rm -it -u "$(id -u):$(id -g)" \ + -v $(pwd):/usr/src -w /usr/src curl/curl sh -c " set -e autoreconf -fi ./configure --without-ssl --without-libpsl From 241c14d97f43913e4fd1b9491dcd1616a7d90879 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Tue, 16 Apr 2024 23:57:00 +0200 Subject: [PATCH 3/4] shellchecked more --- scripts/dmaketgz | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/dmaketgz b/scripts/dmaketgz index afdd4e66f3cbbb..a954b750cf2e5b 100755 --- a/scripts/dmaketgz +++ b/scripts/dmaketgz @@ -40,7 +40,7 @@ docker build \ -t curl/curl . docker run --rm -it -u "$(id -u):$(id -g)" \ - -v $(pwd):/usr/src -w /usr/src curl/curl sh -c " + -v "$(pwd):/usr/src" -w /usr/src curl/curl sh -c " set -e autoreconf -fi ./configure --without-ssl --without-libpsl From d5a06b5a8ac9f376972e21a1dcc28335fd39a850 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Wed, 17 Apr 2024 00:17:57 +0200 Subject: [PATCH 4/4] fixup set -eu as well --- scripts/dmaketgz | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/dmaketgz b/scripts/dmaketgz index a954b750cf2e5b..6603a38ec7f65d 100755 --- a/scripts/dmaketgz +++ b/scripts/dmaketgz @@ -25,6 +25,8 @@ # ########################################################################### +set -eu + version="${1:-}" if [ -z "$version" ]; then