From 9bd0bcc38579556bf416139f94fae36467d6b77a Mon Sep 17 00:00:00 2001 From: Thomas Huth Date: Mon, 28 Nov 2022 10:25:51 +0100 Subject: scripts/make-release: Add a simple help text for the script MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Print a simple help text if the script has been called with the wrong amount of parameters. Message-Id: <20221128092555.37102-2-thuth@redhat.com> Reviewed-by: Alex Bennée Signed-off-by: Thomas Huth --- scripts/make-release | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'scripts/make-release') diff --git a/scripts/make-release b/scripts/make-release index 05b14ecc95..4be9b3b9ce 100755 --- a/scripts/make-release +++ b/scripts/make-release @@ -10,6 +10,12 @@ # This work is licensed under the terms of the GNU GPLv2 or later. # See the COPYING file in the top-level directory. +if [ $# -ne 2 ]; then + echo "Usage:" + echo " $0 gitrepo version" + exit 0 +fi + src="$1" version="$2" destination=qemu-${version} -- cgit 1.4.1 From aa4609dcb8788da7958fe8f6bf29ca0ad61ddb8c Mon Sep 17 00:00:00 2001 From: Thomas Huth Date: Mon, 28 Nov 2022 10:25:52 +0100 Subject: scripts/make-release: Only clone single branches to speed up the script MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Using --single-branch and --depth 1 here helps to speed up the process a little bit and helps to save some networking bandwidth. Message-Id: <20221128092555.37102-3-thuth@redhat.com> Reviewed-by: Alex Bennée Signed-off-by: Thomas Huth --- scripts/make-release | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'scripts/make-release') diff --git a/scripts/make-release b/scripts/make-release index 4be9b3b9ce..44a9d86a04 100755 --- a/scripts/make-release +++ b/scripts/make-release @@ -20,10 +20,12 @@ src="$1" version="$2" destination=qemu-${version} -git clone "${src}" ${destination} +git clone --single-branch -b "v${version}" -c advice.detachedHead=false \ + "${src}" ${destination} + pushd ${destination} -git checkout "v${version}" -git submodule update --init + +git submodule update --init --single-branch (cd roms/seabios && git describe --tags --long --dirty > .version) (cd roms/skiboot && ./make_version.sh > .version) # Fetch edk2 submodule's submodules, since it won't have access to them via @@ -34,7 +36,7 @@ git submodule update --init # submodule dependencies, so we continue to handle these on a case-by-case # basis for now. (cd roms/edk2 && \ - git submodule update --init -- \ + git submodule update --init --depth 1 -- \ ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3 \ BaseTools/Source/C/BrotliCompress/brotli \ CryptoPkg/Library/OpensslLib/openssl \ -- cgit 1.4.1