Skip to content

Commit

Permalink
add publish action
Browse files Browse the repository at this point in the history
  • Loading branch information
iCodeSometime committed Nov 24, 2022
1 parent df2734e commit 3d47008
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 9 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: publish

on:
release:
types: [published]

env:
CARGO_TERM_COLOR: always

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Build
run: cargo build --verbose
- name: Run tests
run: cargo test --verbose
- name: Publish
run: cargo publish --token '${{ secrets.CARGO_REGISTRY_TOKEN }}'
17 changes: 8 additions & 9 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,22 +1,21 @@
name: Rust
name: test

on:
push:
branches: [ "release" ]
branches: ["release"]
pull_request:
branches: [ "release" ]
branches: ["release"]

env:
CARGO_TERM_COLOR: always

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Build
run: cargo build --verbose
- name: Run tests
run: cargo test --verbose
- uses: actions/checkout@v3
- name: Build
run: cargo build --verbose
- name: Run tests
run: cargo test --verbose

0 comments on commit 3d47008

Please sign in to comment.