mirror of
https://github.com/flutter/flutter
synced 2024-10-12 19:23:02 +00:00
handle missing curl (#27295)
This commit is contained in:
parent
8ea8b18fb9
commit
3d2f98498f
|
@ -22,6 +22,23 @@ ENGINE_STAMP="$FLUTTER_ROOT/bin/cache/engine-dart-sdk.stamp"
|
|||
ENGINE_VERSION=`cat "$FLUTTER_ROOT/bin/internal/engine.version"`
|
||||
|
||||
if [ ! -f "$ENGINE_STAMP" ] || [ "$ENGINE_VERSION" != `cat "$ENGINE_STAMP"` ]; then
|
||||
command -v curl > /dev/null 2>&1 || {
|
||||
echo
|
||||
echo 'Missing "curl" tool. Unable to download Dart SDK.'
|
||||
case "$(uname -s)" in
|
||||
Darwin)
|
||||
echo 'Consider running "brew install curl".'
|
||||
;;
|
||||
Linux)
|
||||
echo 'Consider running "sudo apt-get install curl".'
|
||||
;;
|
||||
*)
|
||||
echo "Please install curl."
|
||||
;;
|
||||
esac
|
||||
echo
|
||||
exit 1
|
||||
}
|
||||
echo "Downloading Dart SDK from Flutter engine $ENGINE_VERSION..."
|
||||
|
||||
case "$(uname -s)" in
|
||||
|
|
Loading…
Reference in a new issue