Skip to content

Instantly share code, notes, and snippets.

@xlionjuan
xlionjuan / delete-old-release.yml
Created March 30, 2024 21:15
Delete old Release with actions/github-script@v7
steps:
- name: Delete old Release
uses: actions/github-script@v7
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
const { owner, repo } = context.repo
// Fetch the latest release information
const latestRelease = await github.rest.repos.getLatestRelease({
owner,