Skip to content

Commit

Permalink
ci: use actions for nightly creation
Browse files Browse the repository at this point in the history
  • Loading branch information
kirides committed Aug 29, 2023
1 parent 8913913 commit 01f98da
Showing 1 changed file with 16 additions and 15 deletions.
31 changes: 16 additions & 15 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -102,21 +102,22 @@ jobs:
run: |
(Get-FileHash "${{env.RELEASE_DIR}}.zip" -Algorithm SHA256).hash | Out-File -FilePath "${{env.RELEASE_DIR}}.zip.sha256"
type "${{env.RELEASE_DIR}}.zip.sha256"
- name: Create nightly github release
- name: Delete old nightly
if: github.ref_name == 'master'
run: |
gh release delete nightly --yes --cleanup-tag
gh release create nightly --prerelease --title "Nightly" --notes "Generated release from GitHub Actions"
echo "Ignore 'Validation Failed' results. Expected since only the first job that reaches this step can create the release."
exit 0
uses: dev-drprasad/[email protected]
with:
delete_release: true
tag_name: nightly
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Upload artifacts to github release
if: github.ref_name == 'master'
run: |
gh release upload nightly "${{env.RELEASE_DIR}}.zip" --clobber
gh release upload nightly "${{env.RELEASE_DIR}}.zip.sha256" --clobber
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
- name: Create new nightly
uses: ncipollo/release-action@v1
with:
name: Nightly
generateReleaseNotes: true
prerelease: true
artifacts: "${{env.RELEASE_DIR}}.zip,{{env.RELEASE_DIR}}.zip.sha256"
tag: nightly
token: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 01f98da

Please sign in to comment.