From 5753d8d396faca9fee17c346c2e751858c543362 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Christian=20P=C3=A9rez-Llamas?= <932644+chris-zen@users.noreply.github.com> Date: Sun, 16 Jan 2022 19:49:56 +0100 Subject: [PATCH] Fix cargo login and test job triggered on tags (#35) --- .github/workflows/deploy.yaml | 13 ++++--------- .github/workflows/test.yaml | 5 ++++- 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml index 251761048..98a93ae85 100755 --- a/.github/workflows/deploy.yaml +++ b/.github/workflows/deploy.yaml @@ -5,14 +5,14 @@ on: tags: [ "*" ] jobs: - docs: + deploy: runs-on: macOS-latest steps: - uses: actions/checkout@v2 - name: Install Rust uses: actions-rs/toolchain@v1 with: - toolchain: stable + toolchain: 1.51.0 override: true - uses: Swatinem/rust-cache@v1 @@ -32,10 +32,5 @@ jobs: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: target/doc - - name: Login into crates.io - run: cargo login ${CRATES_TOKEN} - env: - CRATES_IO_TOKEN: ${{ secrets.CRATES_TOKEN }} - - name: Publish into crates.io - run: cargo publish - + - name: Publish to crates.io + run: cargo login ${{ secrets.CARGO_TOKEN }} && cargo publish diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 1e336e699..d8457d8b5 100755 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -1,6 +1,9 @@ name: Test -on: [push, pull_request] +on: + push: + tags-ignore: [ "*" ] + pull_request: {} jobs: test: