Skip to content

Commit

Permalink
CI: add publish to crates-io workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
boozook committed Sep 12, 2023
1 parent 1a53ed4 commit e847ad8
Showing 1 changed file with 48 additions and 0 deletions.
48 changes: 48 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Publish
on:
workflow_dispatch:
inputs:
sdk:
description: "Version of Playdate SDK, needed to validate crates."
default: latest
type: string
required: true
push:
branches: [main, master, "**"]

schedule:
- cron: "0 0 * * 1"

env:
CARGO_NET_RETRY: 10
RUSTUP_MAX_RETRIES: 10
CARGO_TERM_COLOR: always
CARGO_TERM_PROGRESS_WHEN: never

jobs:
crates-io:
runs-on: ubuntu-latest
defaults:
run:
shell: bash

steps:
- uses: actions/checkout@v4

- name: Install Playdate SDK
id: sdk
uses: pd-rs/get-playdate-sdk@main
with:
version: latest

- name: SDK ${{ steps.sdk.outputs.version }} installed
run: which pdc && pdc --version

- name: Publish
uses: katyo/publish-crates@v2
with:
# args: -v
dry-run: true
# ignore-unpublished-changes: true
check-repo: true
registry-token: ${{ secrets.CARGO_REGISTRY_TOKEN }}

0 comments on commit e847ad8

Please sign in to comment.