-
-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: allow specifying custom release-plz source for testing
- Loading branch information
Showing
1 changed file
with
24 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -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. | ||
|
@@ -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 | ||
|