OSDN Git Service

Release workflow: create source archive in the presence of hengband-en.spec
authorEric Branlund <ebranlund@fastmail.com>
Thu, 7 Mar 2024 19:20:16 +0000 (12:20 -0700)
committerEric Branlund <ebranlund@fastmail.com>
Thu, 7 Mar 2024 19:20:16 +0000 (12:20 -0700)
.github/workflows/release.yaml

index 68dea9e..253cfc5 100644 (file)
@@ -163,7 +163,10 @@ jobs:
           ./bootstrap
           ./configure --disable-japanese --disable-net
           make distdir
-          mv "${{ steps.store_config.outputs.name }}"-* "$out"
+          n_name=`find . -maxdepth 1 -type d -name "${{ steps.store.config.outputs.name }}"'-*' -print | wc -l`
+          name=`find . -maxdepth 1 -type d -name "${{ steps.store.config.outputs.name }}"'-*' -print`
+          test x"$n_name" != x1 || exit 1
+          test x"$name" == x"$out" || mv "$name" "$out"
           tar -cBf - "$out" | gzip -c - >"$out".tar.gz
 
       - name: Create Artifact with Source Archive Path