subosito / flutter-action

Flutter environment for use in GitHub Actions. It works on Linux, Windows, and macOS.
MIT License
2.16k stars 191 forks source link

Make it possible to pipe `setup.sh` to shell and make it independent of GHA #295

Open bartekpacia opened 2 months ago

bartekpacia commented 2 months ago

The setup.sh is a core of this action, and it should be relatively easy to make it GitHub Actions-independent.

Then this script could be easily used e.g. when doing one-off Flutter install, or building a container image:

 curl -fsSL https://raw.githubusercontent.com/subosito/flutter-action/v2/setup.sh | bash -s -- -n '3.19.0' -a 'arm64' -c "$PWD" 'stable'

Relevant StackOverflow question: Passing parameters to bash when executing a script fetched by curl

Different takes on whether piping curl to shell is a good idea: