-
Notifications
You must be signed in to change notification settings - Fork 20
27 lines (26 loc) · 981 Bytes
/
CleanUp.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
# This job cleans up old pre-releases and pre-releases packages retaining the last 40 versions
name: Clean up old pre-releases and packages
on:
schedule:
- cron: '0 8 * * 1' # run at 8am every Monday
workflow_dispatch: # allow manual triggering
permissions:
actions: write # required for reading & deleting github actions artifacts
contents: write # required for reading releases
jobs:
cleanup:
name: Clean up old pre-releases and packages
runs-on: ubuntu-latest
steps:
# https://github.com/marketplace/actions/delete-releases
- name: Delete old 'hyperlight-wasm' releases
uses: sgpublic/[email protected]
with:
release-drop: false
pre-release-drop: true
pre-release-keep-count: 5
pre-release-drop-tag: true
draft-drop: false
env:
GITHUB_TOKEN: ${{ github.token }}