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: support flutter-version input #9

Merged
merged 4 commits into from
Aug 10, 2023
Merged
Show file tree
Hide file tree
Changes from 2 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
4 changes: 3 additions & 1 deletion .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: ./
with:
flutter-version: 3.10.0
- if: runner.os != 'Windows'
run: |
if [[ $(shorebird --version) =~ "Shorebird Engine • revision" ]]; then
Expand All @@ -35,4 +37,4 @@ jobs:
} else {
Write-Output "❌ Shorebird CLI is not installed."
exit 1
}
}
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,18 @@ Installs and sets up [Shorebird](https://github.com/shorebirdtech/shorebird) for

✅ Adds `shorebird` to the system path

✅ Configures the specified version of Flutter

## Usage

```yaml
steps:
- uses: shorebirdtech/setup-shorebird@v0
- run: shorebird --version
```

## Inputs

The action takes the following inputs:

- `flutter-version`: Which version of Flutter to install alongside Shorebird (e.g. 3.10.6)
9 changes: 9 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ branding:
icon: check-circle
color: yellow

inputs:
flutter-version:
description: The Flutter version to use alongside Shorebird
required: false

runs:
using: composite
steps:
Expand All @@ -25,3 +30,7 @@ runs:
Add-Content $env:GITHUB_PATH "$installDirectory\bin"
Write-Output "added $installDirectory\bin to GITHUB_PATH"
shell: pwsh
- name: 🐦 Install Flutter
if: ${{ inputs.flutter-version }}
run: shorebird flutter versions use ${{ inputs.flutter-version }}
shell: bash
Loading