Skip to content

Commit

Permalink
gh action for nightly releases (#114)
Browse files Browse the repository at this point in the history
  • Loading branch information
steezeburger authored Jun 20, 2024
1 parent bc89d90 commit 89ebf56
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/build-for-release.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
name: Build For Release

# Build `astria-go` binaries for multiple architectures whenever
# a release is created, using the tag name as the cli's version

on:
release:
types: [created]
Expand Down
33 changes: 33 additions & 0 deletions .github/workflows/nightly-release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Nightly Release

# Creates a nightly release which triggers build-for-release

on:
schedule:
# every day at 6AM UTC. late night for America, early morning for Europe
- cron: '0 6 * * *'
workflow_dispatch:

permissions:
contents: write
packages: write

jobs:
create-nightly-release:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Set current date in environment variable
run: echo "RELEASE_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
- name: Create Nightly Release
id: create_release
uses: softprops/action-gh-release@v2
with:
name: "Nightly Release ${{ env.RELEASE_DATE }}"
body: "${{ env.RELEASE_DATE }} nightly release of `astria-go`"
tag_name: nightly-${{ env.RELEASE_DATE }}
prerelease: true
draft: false
generate_release_notes: true
token: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 89ebf56

Please sign in to comment.