Update Donors #606
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Update Donors | |
on: | |
schedule: | |
- cron: '0 */8 * * *' | |
workflow_dispatch: | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
update-donors: | |
if: github.repository == 'bevyengine/bevy-donors' | |
runs-on: ubuntu-latest | |
timeout-minutes: 30 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: dtolnay/rust-toolchain@stable | |
- name: Generate donors.toml and metrics.toml | |
env: | |
STRIPE_SECRET_KEY: ${{ secrets.STRIPE_SECRET_KEY }} | |
run: | | |
cargo run | |
- name: Tag the repository | |
id: tag | |
run: | | |
# See https://docs.github.com/en/get-started/using-git/dealing-with-special-characters-in-branch-and-tag-names | |
TAG=v$(date -Iseconds | sed 's/[T:\+]/-/g') | |
echo "$TAG" | |
echo "tag=$TAG" >> $GITHUB_OUTPUT | |
git config user.name "GitHub Action" | |
git config user.email "github_action@bevyengine.org" | |
git tag -a $TAG -m "Published version $TAG" ${GITHUB_SHA} | |
git push origin $TAG | |
- name: Release | |
uses: softprops/action-gh-release@v2 | |
with: | |
tag_name: ${{ steps.tag.outputs.tag }} | |
files: | | |
donors.toml | |
metrics.toml | |
- name: trigger website deploy | |
run: gh --repo bevyengine/bevy-website workflow run deploy.yml | |
env: | |
GITHUB_TOKEN: ${{ secrets.CART_PAT }} |