Skip to content

Commit

Permalink
feat: more cicd to publish
Browse files Browse the repository at this point in the history
  • Loading branch information
NexRX committed Dec 21, 2023
1 parent 3401509 commit 56063e4
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 3 deletions.
32 changes: 32 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Publish

on:
push:
tags:
- '*' # Push events to every tag not containing /
workflow_dispatch:

env:
CARGO_TERM_COLOR: always

jobs:
publish:
name: Publish
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v3

- name: Install stable toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true

- name: Run tests
run: cargo test --verbose

- run: cargo publish --token ${CRATES_TOKEN}
env:
CRATES_TOKEN: ${{ secrets.CRATES_TOKEN }}
6 changes: 3 additions & 3 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
name: Rust
name: Test

on:
push:
branches: [ "main" ]
branches: "**"
pull_request:
branches: [ "main" ]
branches: "**"

env:
CARGO_TERM_COLOR: always
Expand Down

0 comments on commit 56063e4

Please sign in to comment.