Skip to content

Commit

Permalink
Update auto-nightly.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
ale5000-git authored Jan 21, 2025
1 parent a0773b3 commit 0fefc5e
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/auto-nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,14 +79,18 @@ jobs:
if(response && response.message) console.error('::error::' + response.message);
throw new Error('getReleaseByTag failed.');
}
await github.rest.git.deleteRef({
await github.rest.git.updateRef({
owner: context.repo.owner,
repo: context.repo.repo,
ref: 'tags/nightly'
ref: 'tags/nightly',
sha: context.sha,
force: true
}).then(response => {
console.log('Previous nightly tag updated.');
}).catch(error => {
console.log('::: ' + error.message)
if(error.status !== 422 || error.message !== 'Reference does not exist') throw error;
});
console.log('Previous nightly tag deleted.');
- name: "Create nightly release"
uses: softprops/action-gh-release@v2
if: "${{ github.event_name != 'pull_request' && steps.build.outputs.ZIP_BUILD_TYPE_SUPPORTED == 'true' && steps.build.outputs.ZIP_IS_ALPHA == 'true' }}"
Expand Down

0 comments on commit 0fefc5e

Please sign in to comment.