From 6c683a86ce3363cff835842b27e4bec652410b52 Mon Sep 17 00:00:00 2001 From: Simone Cottini Date: Mon, 18 Dec 2023 10:53:09 +0100 Subject: [PATCH 1/3] Fix release --- .github/workflows/cd.yml | 1 - Makefile.toml | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index c06086e..ad72ff7 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -12,7 +12,6 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - uses: taiki-e/install-action@cargo-release - uses: taiki-e/install-action@cargo-make - name: Get version run: | diff --git a/Makefile.toml b/Makefile.toml index 7f53423..a00ccf2 100644 --- a/Makefile.toml +++ b/Makefile.toml @@ -38,4 +38,4 @@ env = { "RUSTDOCFLAGS" = "-Dwarnings" } [tasks.release] description = "Task to release the package to crates.io" command = "cargo" -args = ["release", "publish", "--no-confirm", "--allow-branch \"*\"", "--all-features", "--workspace", "--execute"] \ No newline at end of file +args = ["publish", "--no-verify"] \ No newline at end of file From 877993e4fe12e65156e774e323db0e3be79a8e28 Mon Sep 17 00:00:00 2001 From: Simone Cottini Date: Mon, 18 Dec 2023 10:55:03 +0100 Subject: [PATCH 2/3] Fix release pt.2 --- .github/workflows/ci.yml | 3 +++ Makefile.toml | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 805c699..aabaa4b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -13,6 +13,9 @@ jobs: steps: - uses: actions/checkout@v4 - uses: Swatinem/rust-cache@v2 + - uses: taiki-e/install-action@v2 + with: + tool: cargo-release@0.24 - uses: taiki-e/install-action@cargo-make - run: cargo make fmt-check - run: cargo make clippy diff --git a/Makefile.toml b/Makefile.toml index a00ccf2..7f53423 100644 --- a/Makefile.toml +++ b/Makefile.toml @@ -38,4 +38,4 @@ env = { "RUSTDOCFLAGS" = "-Dwarnings" } [tasks.release] description = "Task to release the package to crates.io" command = "cargo" -args = ["publish", "--no-verify"] \ No newline at end of file +args = ["release", "publish", "--no-confirm", "--allow-branch \"*\"", "--all-features", "--workspace", "--execute"] \ No newline at end of file From ad831904f35923b7278e90f4650ff06e0dbc6651 Mon Sep 17 00:00:00 2001 From: Simone Cottini Date: Mon, 18 Dec 2023 10:58:53 +0100 Subject: [PATCH 3/3] Fix release pt.3 --- .github/workflows/cd.yml | 17 +++++------------ .github/workflows/ci.yml | 3 --- 2 files changed, 5 insertions(+), 15 deletions(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index ad72ff7..0ae03e7 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -12,19 +12,12 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 + - uses: taiki-e/install-action@v2 + with: + tool: cargo-release@0.24 - uses: taiki-e/install-action@cargo-make - - name: Get version - run: | - POSITIONAL_VERSION=$(grep -m1 '^version' positional/Cargo.toml | cut -d'"' -f2) - POSITIONAL_DERIVE_VERSION=$(grep -m1 '^version' positional_derive/Cargo.toml | cut -d'"' -f2) - echo "POSITIONAL_VERSION=$POSITIONAL_VERSION" >> $GITHUB_ENV - echo "POSITIONAL_DERIVE_VERSION=$POSITIONAL_DERIVE_VERSION" >> $GITHUB_ENV - - name: Check version - if: ${{ github.event.release.tag_name != env.POSITIONAL_VERSION || github.event.release.tag_name != env.POSITIONAL_DERIVE_VERSION }} - run: | - echo "Github ref tag [${{ github.event.release.tag_name }}] is different from positional Cargo.toml version [${{ env.POSITIONAL_VERSION }}] or positional_derive Cargo.toml version [${{ env.POSITIONAL_DERIVE_VERSION }}]" - exit 1 - - run: cargo login "$CARGO_AUTH_KEY" + - name: login + run: cargo login "$CARGO_AUTH_KEY" env: CARGO_AUTH_KEY: ${{ secrets.CARGO_AUTH_KEY }} - run: cargo make release diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index aabaa4b..805c699 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -13,9 +13,6 @@ jobs: steps: - uses: actions/checkout@v4 - uses: Swatinem/rust-cache@v2 - - uses: taiki-e/install-action@v2 - with: - tool: cargo-release@0.24 - uses: taiki-e/install-action@cargo-make - run: cargo make fmt-check - run: cargo make clippy