From c8989b3b2fb63626be8290c5eb8a169aea669783 Mon Sep 17 00:00:00 2001 From: Anton Baliasnikov Date: Tue, 26 Nov 2024 11:03:51 +0000 Subject: [PATCH] chore: use correct way to pass secrets to workflow call --- .github/workflows/release-plz.yaml | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/.github/workflows/release-plz.yaml b/.github/workflows/release-plz.yaml index 5866ea3..937b5cb 100644 --- a/.github/workflows/release-plz.yaml +++ b/.github/workflows/release-plz.yaml @@ -2,15 +2,14 @@ name: Release-plz on: workflow_call: - inputs: + secrets: github_token: - type: string description: 'GitHub token' required: true cargo_registry_token: - type: string description: 'Cargo registry token' required: true + inputs: run_tests: type: boolean description: 'Run tests before release' @@ -28,6 +27,7 @@ jobs: uses: actions/checkout@v4 with: fetch-depth: 0 + token: ${{ secrets.github_token }} - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable @@ -41,8 +41,8 @@ jobs: with: command: release env: - GITHUB_TOKEN: ${{ inputs.github_token }} - CARGO_REGISTRY_TOKEN: ${{ inputs.cargo_registry_token }} + GITHUB_TOKEN: ${{ secrets.github_token }} + CARGO_REGISTRY_TOKEN: ${{ secrets.cargo_registry_token }} # Create a PR with the new versions and changelog, preparing the next release. release-plz-pr: @@ -56,6 +56,7 @@ jobs: uses: actions/checkout@v4 with: fetch-depth: 0 + token: ${{ secrets.github_token }} - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable @@ -65,5 +66,5 @@ jobs: with: command: release-pr env: - GITHUB_TOKEN: ${{ inputs.github_token }} - CARGO_REGISTRY_TOKEN: ${{ inputs.cargo_registry_token }} + GITHUB_TOKEN: ${{ secrets.github_token }} + CARGO_REGISTRY_TOKEN: ${{ secrets.cargo_registry_token }}