Populate PUB_ENVIRONMENT for initial pub get and correctly detect APPVEYOR as bot (#9725)

* Populate PUB_ENVIRONMENT for initial pub get

* review comments

* change order
This commit is contained in:
Michael Goderbauer
2017-05-02 11:25:59 -07:00
committed by GitHub
parent 49d32d35ea
commit c256e6d557
3 changed files with 27 additions and 3 deletions

View File

@@ -16,12 +16,15 @@ import 'platform.dart';
bool get isRunningOnBot {
// https://docs.travis-ci.com/user/environment-variables/#Default-Environment-Variables
// https://www.appveyor.com/docs/environment-variables/
// CHROME_HEADLESS is one property set on Flutter's Chrome Infra bots.
return
platform.environment['TRAVIS'] == 'true' ||
platform.environment['BOT'] == 'true' ||
platform.environment['CONTINUOUS_INTEGRATION'] == 'true' ||
platform.environment['CHROME_HEADLESS'] == '1';
platform.environment['CHROME_HEADLESS'] == '1' ||
platform.environment['APPVEYOR'] == 'true' ||
platform.environment['CI'] == 'true';
}
String hex(List<int> bytes) {