Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(CI): allow push to crates.io for version tag #53

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -119,3 +119,22 @@ jobs:
with:
command: clippy
args: -- -D warnings

publish:
name: Publish Package
needs: [check, lints, test]
if: startsWith(github.ref, 'refs/tags/v')
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The tags we use for now don't start with v, so either

  • we start using v{MAJOR}.{MINOR}.{PATCH} now, or
  • we match against refs/tags/ instead

I don't have any strong opinion on the matter.

runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- name: login
env:
SUPER_SECRET: ${{ secrets.CARGO_TOKEN }}
run: cargo login "$SUPER_SECRET"
shell: bash

- name: publish
uses: actions-rs/cargo@v1
with:
command: publish