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/remove-files.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/remove-files.yml')
-rw-r--r-- | .github/workflows/remove-files.yml | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/.github/workflows/remove-files.yml b/.github/workflows/remove-files.yml new file mode 100644 index 0000000..1d72362 --- /dev/null +++ b/.github/workflows/remove-files.yml @@ -0,0 +1,60 @@ +name: hdf5 dev remove-files + +# Controls when the action will run. Triggers the workflow on a schedule +on: + workflow_call: + inputs: + use_tag: + description: 'Release version tag' + type: string + required: false + default: snapshot + use_environ: + description: 'Environment to locate files' + type: string + required: true + default: snapshots + file_base: + description: "The common base name of the source tarballs" + required: true + type: string + +# Minimal permissions to be inherited by any job that doesn't declare its own permissions +permissions: + contents: read + +# Previous workflows must pass to get here so tag the commit that created the files +jobs: + PreRelease-delfiles: + runs-on: ubuntu-latest + environment: ${{ inputs.use_environ }} + permissions: + contents: write + steps: + - name: Get file base name + id: get-file-base + run: | + FILE_NAME_BASE=$(echo "${{ inputs.file_base }}") + echo "FILE_BASE=$FILE_NAME_BASE" >> $GITHUB_OUTPUT + + - name: PreRelease delete from tag + id: delete_prerelease + if: ${{ (inputs.use_environ == 'snapshots') }} + uses: mknejp/delete-release-assets@v1 + with: + token: ${{ github.token }} + tag: "${{ inputs.use_tag }}" + assets: | + ${{ steps.get-file-base.outputs.FILE_BASE }}-hdf5_compat_report.html + ${{ steps.get-file-base.outputs.FILE_BASE }}-hdf5_hl_compat_report.html + ${{ steps.get-file-base.outputs.FILE_BASE }}-hdf5_cpp_compat_report.html + ${{ steps.get-file-base.outputs.FILE_BASE }}-java_compat_report.html + ${{ steps.get-file-base.outputs.FILE_BASE }}.doxygen.zip + ${{ steps.get-file-base.outputs.FILE_BASE }}.tar.gz + ${{ steps.get-file-base.outputs.FILE_BASE }}.zip + ${{ steps.get-file-base.outputs.FILE_BASE }}-osx12.tar.gz + ${{ steps.get-file-base.outputs.FILE_BASE }}-ubuntu-2204_gcc.tar.gz + ${{ steps.get-file-base.outputs.FILE_BASE }}-ubuntu-2204_gcc_s3.tar.gz + ${{ steps.get-file-base.outputs.FILE_BASE }}-win-vs2022_cl.zip + ${{ steps.get-file-base.outputs.FILE_BASE }}-ubuntu-2204_intel.tar.gz + ${{ steps.get-file-base.outputs.FILE_BASE }}-win-vs2022_intel.zip |