-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(ci): support custom turbo version for ci (#9913)
### Description Our release flow installs the most recent version of turbo to run tests even if it's deprecated. This allows that to be overriden so we can still release forward after a bad release. ### Testing Instructions <!-- Give a quick description of steps to test your changes. -->
- Loading branch information
Showing
2 changed files
with
30 additions
and
4 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 |
---|---|---|
@@ -1,12 +1,29 @@ | ||
name: "Install Global Turbo" | ||
description: "Installs turbo globally. Expects Node and npm to already be installed" | ||
|
||
inputs: | ||
turbo-version: | ||
description: "Specify a Turbo version or tag (e.g., 2.0.5, latest, beta, canary)" | ||
required: false | ||
default: "" | ||
|
||
runs: | ||
using: "composite" | ||
steps: | ||
- name: Determine Turbo Version | ||
id: determine-version | ||
shell: bash | ||
run: | | ||
if [[ -n "${{ inputs.turbo-version }}" ]]; then | ||
VERSION="${{ inputs.turbo-version }}" | ||
else | ||
VERSION=$(npm view turbo --json | jq -r '.versions | map(select(test("^2\\."))) | last') | ||
echo "No version provided, using latest 2.x version: $VERSION" | ||
fi | ||
echo "TURBO_VERSION=$VERSION" >> $GITHUB_ENV | ||
- name: Install Turbo globally | ||
shell: bash | ||
run: | | ||
VERSION=$(npm view turbo --json | jq -r '.versions | map(select(test("2."))) | last') | ||
echo "Latest published version: $VERSION" | ||
npm i -g turbo@$VERSION | ||
echo "Installing turbo@$TURBO_VERSION..." | ||
npm i -g turbo@$TURBO_VERSION |
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