Skip to content

Commit

Permalink
github: Create publishing workflow on tag push, disable `cargo-releas…
Browse files Browse the repository at this point in the history
…e` publish (#52)

In this release workflow (already employed by other Traverse Research
crates) `cargo-release` does the gruntwork and pushes a tag, but does
not publish to crates.io yet; this'll be done by the CI.
  • Loading branch information
MarijnS95 authored Jan 13, 2023
1 parent 2dcfb9e commit 70401e7
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Publish

on:
push:
tags:
paths: "/Cargo.toml"

jobs:
Publish:
if: github.repository_owner == 'Traverse-Research'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- name: Publish
uses: actions-rs/cargo@v1
with:
command: publish
args: --token ${{ secrets.cratesio_token }}
1 change: 1 addition & 0 deletions release.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ tag-message = "Release {{version}}"
tag-name = "{{version}}"
sign-commit = true
sign-tag = true
publish = false

pre-release-replacements = [
{file="README.md", search="hassle-rs = .*", replace="{{crate_name}} = \"{{version}}\""},
Expand Down

0 comments on commit 70401e7

Please sign in to comment.