Skip to content

Commit 42361d3

Browse files
committed
[install] in archiver.yml, fix prerelease handling in softprops action
1 parent b09463f commit 42361d3

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

.github/workflows/archiver.yml

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -128,9 +128,11 @@ jobs:
128128
echo "" >> ${WORKDIR}/versiontag.txt
129129
echo "This is a test or pre-release tag: to use it, install it directly as follows" >> ${WORKDIR}/versiontag.txt
130130
echo "" >> ${WORKDIR}/versiontag.txt
131-
echo "```" >> ${WORKDIR}/versiontag.txt
131+
echo "<sub>" >> ${WORKDIR}/versiontag.txt # hack to display smaller text in markdown
132+
###echo "\`\`\`" >> ${WORKDIR}/versiontag.txt
132133
echo "MG5_aMC>install cudacpp --cudacpp_tarball=https://github.com/${REPOSITORY}/releases/download/${tagname}/cudacpp.tar.gz" >> ${WORKDIR}/versiontag.txt
133-
echo "```" >> ${WORKDIR}/versiontag.txt
134+
###echo "\`\`\`" >> ${WORKDIR}/versiontag.txt
135+
echo "</sub>" >> ${WORKDIR}/versiontag.txt # hack to display smaller text in markdown
134136
echo "" >> ${WORKDIR}/versiontag.txt
135137
echo "---" >> ${WORKDIR}/versiontag.txt
136138
fi
@@ -159,7 +161,7 @@ jobs:
159161
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
160162

161163
- name: delete_runningtag_releaseandtag
162-
if: ${{ env.tagname_isprerelease != '0' }}
164+
if: ${{ env.TAGNAME_ISPRERELEASE != '0' }}
163165
# See https://cli.github.com/manual/gh_release_delete
164166
# See https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/using-github-cli-in-workflows
165167
run: |
@@ -181,7 +183,7 @@ jobs:
181183
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
182184

183185
- name: create_runningtag
184-
if: ${{ env.tagname_isprerelease != '0' }}
186+
if: ${{ env.TAGNAME_ISPRERELEASE != '0' }}
185187
run: |
186188
echo "Current directory is $(pwd)"
187189
echo "WORKDIR is ${WORKDIR}"
@@ -213,7 +215,7 @@ jobs:
213215
uses: softprops/action-gh-release@v2
214216
with:
215217
name: ${{ env.TAGNAME }}
216-
prerelease: ${{ env.TAGNAME_ISPRERELEASE }}
218+
prerelease: ${{ env.TAGNAME_ISPRERELEASE != '0' }}
217219
body_path: versiontag.txt
218220
# Previous attempt to upload files from ${HOME}/VERSION.txt and ${HOME}/cudacpp.tar.gz failed
219221
# The current implementation uploads files from the default ${WORKDIR} (without giving the explicit full path)
@@ -224,7 +226,7 @@ jobs:
224226
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
225227

226228
- name: release_runningtag
227-
if: ${{ env.tagname_isprerelease != '0' }}
229+
if: ${{ env.TAGNAME_ISPRERELEASE != '0' }}
228230
# See https://github.com/softprops/action-gh-release
229231
uses: softprops/action-gh-release@v2
230232
with:
@@ -240,7 +242,7 @@ jobs:
240242
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
241243

242244
- name: create_infodat
243-
if: ${{ env.tagname_isprerelease != '0' }}
245+
if: ${{ env.TAGNAME_ISPRERELEASE != '0' }}
244246
run: |
245247
echo "Current directory is $(pwd)"
246248
echo "WORKDIR is ${WORKDIR}"
@@ -255,14 +257,14 @@ jobs:
255257
cat ${WORKDIR}/version_info.dat
256258
257259
- name: checkout_INFO
258-
if: ${{ env.tagname_isprerelease != '0' }}
260+
if: ${{ env.TAGNAME_ISPRERELEASE != '0' }}
259261
uses: actions/checkout@v4
260262
with:
261263
ref: INFO
262264
path: branch_INFO
263265

264266
- name: commit_infodat
265-
if: ${{ env.tagname_isprerelease != '0' }}
267+
if: ${{ env.TAGNAME_ISPRERELEASE != '0' }}
266268
run: |
267269
echo "Current directory is $(pwd)"
268270
echo "WORKDIR is ${WORKDIR}"

0 commit comments

Comments
 (0)