Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: allow specifying custom release-plz source for testing #148

Closed
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 24 additions & 2 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,12 @@ inputs:
token:
description: "Token used to publish to the cargo registry"
required: false
tool-repository:
description: "Build custom release-plz for development or testing. Specifies the repository url passed to git clone."
required: false
tool-rev:
description: "Build custom release-plz for development or testing. Specifies the revision passed to git checkout."
required: false
outputs:
# Useful for when https://github.com/MarcoIeni/release-plz/issues/1029 is implemented.
# For now, it just returns an array with `pr` in it.
Expand All @@ -50,10 +56,26 @@ branding:
runs:
using: "composite"
steps:
- name: Install binaries
- name: Install cargo semver-checks
uses: taiki-e/install-action@v2
with:
tool: [email protected]
- name: Install release-plz
if: ${{ ! inputs.tool-repository }}
uses: taiki-e/install-action@v2
with:
tool: [email protected], release-plz@${{ inputs.version }}
tool: release-plz@${{ inputs.version }}
- name: Build custom release-plz
if: ${{ inputs.tool-repository }}
shell: bash
run: |
git clone "${{ inputs.tool-repository }}" ../release-plz
cd ../release-plz
if [[ -n "${{ inputs.tool-rev }}" ]]
then
git checkout "${{ inputs.tool-rev }}"
fi
cargo install --path crates/release_plz
- name: Configure git user from GitHub token
uses: MarcoIeni/[email protected]
- name: Run release-plz
Expand Down