Skip to content

Commit

Permalink
Create rustcd.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
Walkmana-25 authored Dec 3, 2023
1 parent be695df commit 0abf81f
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/rustcd.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Rust CD

on:
release:
types: [created]

env:
CARGO_TERM_COLOR: always

jobs:
cd:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Install Rust
uses: dtolnay/rust-toolchain@stable

- name: Cache cargo dependencies
uses: actions/cache@v3
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.toml') }}

- name: Test
run: cargo test --verbose

- name: Publish
run: cargo publish
env:
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_TOKEN }}

0 comments on commit 0abf81f

Please sign in to comment.