From 18bc5b2d3a942321b2a837444803c0c0dc5d49ad Mon Sep 17 00:00:00 2001 From: Mark Jansen Date: Mon, 9 Sep 2024 14:22:45 +0200 Subject: [PATCH] Add a workaround for git describe not supporting tag+count without hash --- Docker/Dockerfile | 1 - Release_Configure | 7 +++++-- Release_ISOs | 15 +++++++++++---- 3 files changed, 16 insertions(+), 7 deletions(-) diff --git a/Docker/Dockerfile b/Docker/Dockerfile index d94bfbd..54d7ceb 100644 --- a/Docker/Dockerfile +++ b/Docker/Dockerfile @@ -32,7 +32,6 @@ RUN wget https://downloads.sourceforge.net/reactos/RosBE-Unix-2.2.1.tar.bz2 \ && rm -rf RosBE-Unix-2.2.1 RUN git clone https://github.com/reactos/Release_Engineering \ - && mv Release_Engineering/Release_* /usr/local/bin \ && rm -rf Release_Engineering diff --git a/Release_Configure b/Release_Configure index 6170938..8aaad87 100755 --- a/Release_Configure +++ b/Release_Configure @@ -46,9 +46,12 @@ else git checkout "${branch_name}" || exit 1 fi -# Get the suffix from Git if none was entered. +# Get the version from Git if none was entered. if [ "${version}" = "" ]; then - version=`git describe --abbrev=0` + # Output something like '0.4.15-4-ge1e96bf467b5ea' + version_with_hash=`git describe --always` + # Extract the part before the last dash to ignore the commit hash + version=${version_with_hash%-*} fi # Write the config file diff --git a/Release_ISOs b/Release_ISOs index d677c81..9623049 100755 --- a/Release_ISOs +++ b/Release_ISOs @@ -13,13 +13,20 @@ if [ "$ROS_ARCH" = "" ]; then exit 1 fi +if [ "$ROS_ARCH" = "i386" ]; then + ROS_PRETTY_ARCH="x86" +else + ROS_PRETTY_ARCH="$ROS_ARCH" +fi + + # Constants ROOTDIR="$PWD" OUTPUTDIR="output-MinGW-i386" -BOOTCDISO="ReactOS-${version}-${ROS_ARCH}.iso" -BOOTCDZIP="ReactOS-${version}-${ROS_ARCH}-iso.zip" -LIVECDISO="ReactOS-${version}-${ROS_ARCH}-live.iso" -LIVECDZIP="ReactOS-${version}-${ROS_ARCH}-live.zip" +BOOTCDISO="ReactOS-${version}-${ROS_PRETTY_ARCH}.iso" +BOOTCDZIP="ReactOS-${version}-${ROS_PRETTY_ARCH}-iso.zip" +LIVECDISO="ReactOS-${version}-${ROS_PRETTY_ARCH}-live.iso" +LIVECDZIP="ReactOS-${version}-${ROS_PRETTY_ARCH}-live.zip" # Start from a clean state rm -f "${ROOTDIR}/${BOOTCDZIP}"