diff options
author | Allen Byrne <50328838+byrnHDF@users.noreply.github.com> | 2024-02-15 21:32:01 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-02-15 21:32:01 (GMT) |
commit | 7392a102d8ab67c369d2f6208bd4b23711e6ea44 (patch) | |
tree | 0ac0f24bf415e8c20c293157f01f21b51fdaa2fe /.github/workflows/daily-build.yml | |
parent | 410c18b59f8389f113c806917af69378d77ef506 (diff) | |
download | hdf5-7392a102d8ab67c369d2f6208bd4b23711e6ea44.zip hdf5-7392a102d8ab67c369d2f6208bd4b23711e6ea44.tar.gz hdf5-7392a102d8ab67c369d2f6208bd4b23711e6ea44.tar.bz2 |
Delete old snapshot binaries after new snapshots are created (#4020)
Diffstat (limited to '.github/workflows/daily-build.yml')
-rw-r--r-- | .github/workflows/daily-build.yml | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/.github/workflows/daily-build.yml b/.github/workflows/daily-build.yml index a3f965b..37f2f06 100644 --- a/.github/workflows/daily-build.yml +++ b/.github/workflows/daily-build.yml @@ -12,6 +12,26 @@ permissions: # A workflow run is made up of one or more jobs that can run sequentially or # in parallel. jobs: + get-old-names: + runs-on: ubuntu-latest + outputs: + hdf5-name: ${{ steps.gethdf5base.outputs.HDF5_NAME_BASE }} + + steps: + - uses: actions/checkout@v4.1.1 + + - name: Get hdf5 release base name + uses: dsaltares/fetch-gh-release-asset@master + with: + version: 'tags/snapshot' + file: 'last-file.txt' + + - name: Read base-name file + id: gethdf5base + run: echo "HDF5_NAME_BASE=$(cat last-file.txt)" >> $GITHUB_OUTPUT + + - run: echo "hdf5 base name is ${{ steps.gethdf5base.outputs.HDF5_NAME_BASE }}." + call-workflow-tarball: uses: ./.github/workflows/tarball.yml with: @@ -51,3 +71,14 @@ jobs: use_environ: snapshots if: ${{ needs.call-workflow-tarball.outputs.has_changes == 'true' }} + call-workflow-remove: + needs: [get-old-names, call-workflow-tarball, call-workflow-ctest, call-workflow-abi, call-workflow-release] + permissions: + contents: write # In order to allow file deletion + uses: ./.github/workflows/remove-files.yml + with: + file_base: ${{ needs.get-old-names.outputs.hdf5-name }} + use_tag: snapshot + use_environ: snapshots + if: ${{ needs.call-workflow-tarball.outputs.has_changes == 'true' }} + |