Enable GitHub Actions (#1390)

diff --git a/.github/workflows/dart.yml b/.github/workflows/dart.yml
new file mode 100644
index 0000000..8847c36
--- /dev/null
+++ b/.github/workflows/dart.yml
@@ -0,0 +1,197 @@
+# Created with package:mono_repo v3.1.0
+name: Dart CI
+on:
+  push:
+    branches:
+      - main
+      - master
+  pull_request:
+defaults:
+  run:
+    shell: bash
+env:
+  PUB_ENVIRONMENT: bot.github
+  FORCE_TEST_EXIT: true
+
+jobs:
+  job_001:
+    name: mono_repo self validate
+    runs-on: ubuntu-latest
+    steps:
+      - name: Cache Pub hosted dependencies
+        uses: actions/cache@v2
+        with:
+          path: "~/.pub-cache/hosted"
+          key: "os:ubuntu-latest;pub-cache-hosted;dart:stable"
+          restore-keys: |
+            os:ubuntu-latest;pub-cache-hosted
+            os:ubuntu-latest
+      - uses: cedx/setup-dart@v2
+        with:
+          release-channel: stable
+          version: latest
+      - run: dart --version
+      - uses: actions/checkout@v2
+      - run: pub global activate mono_repo 3.1.0
+      - run: pub global run mono_repo generate --validate
+  job_002:
+    name: "OS: linux; SDK: dev; PKGS: pkgs/test, pkgs/test_api, pkgs/test_core; TASKS: [`dartfmt -n --set-exit-if-changed .`, `dartanalyzer --enable-experiment=non-nullable --fatal-infos --fatal-warnings .`]"
+    runs-on: ubuntu-latest
+    steps:
+      - name: Cache Pub hosted dependencies
+        uses: actions/cache@v2
+        with:
+          path: "~/.pub-cache/hosted"
+          key: "os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test-pkgs/test_api-pkgs/test_core;commands:dartfmt-dartanalyzer"
+          restore-keys: |
+            os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test-pkgs/test_api-pkgs/test_core
+            os:ubuntu-latest;pub-cache-hosted;dart:dev
+            os:ubuntu-latest;pub-cache-hosted
+            os:ubuntu-latest
+      - uses: cedx/setup-dart@v2
+        with:
+          release-channel: dev
+      - run: dart --version
+      - uses: actions/checkout@v2
+      - env:
+          PKGS: pkgs/test pkgs/test_api pkgs/test_core
+          TRAVIS_OS_NAME: linux
+        run: tool/ci.sh dartfmt dartanalyzer
+  job_003:
+    name: "OS: linux; SDK: dev; PKG: pkgs/test; TASKS: `xvfb-run -s \"-screen 0 1024x768x24\" pub run --enable-experiment=non-nullable test --preset travis -x phantomjs --total-shards 5 --shard-index 0`"
+    runs-on: ubuntu-latest
+    steps:
+      - name: Cache Pub hosted dependencies
+        uses: actions/cache@v2
+        with:
+          path: "~/.pub-cache/hosted"
+          key: "os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test;commands:command_0"
+          restore-keys: |
+            os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test
+            os:ubuntu-latest;pub-cache-hosted;dart:dev
+            os:ubuntu-latest;pub-cache-hosted
+            os:ubuntu-latest
+      - uses: cedx/setup-dart@v2
+        with:
+          release-channel: dev
+      - run: dart --version
+      - uses: actions/checkout@v2
+      - env:
+          PKGS: pkgs/test
+          TRAVIS_OS_NAME: linux
+        run: tool/ci.sh command_0
+  job_004:
+    name: "OS: linux; SDK: dev; PKG: pkgs/test; TASKS: `xvfb-run -s \"-screen 0 1024x768x24\" pub run --enable-experiment=non-nullable test --preset travis -x phantomjs --total-shards 5 --shard-index 1`"
+    runs-on: ubuntu-latest
+    steps:
+      - name: Cache Pub hosted dependencies
+        uses: actions/cache@v2
+        with:
+          path: "~/.pub-cache/hosted"
+          key: "os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test;commands:command_1"
+          restore-keys: |
+            os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test
+            os:ubuntu-latest;pub-cache-hosted;dart:dev
+            os:ubuntu-latest;pub-cache-hosted
+            os:ubuntu-latest
+      - uses: cedx/setup-dart@v2
+        with:
+          release-channel: dev
+      - run: dart --version
+      - uses: actions/checkout@v2
+      - env:
+          PKGS: pkgs/test
+          TRAVIS_OS_NAME: linux
+        run: tool/ci.sh command_1
+  job_005:
+    name: "OS: linux; SDK: dev; PKG: pkgs/test; TASKS: `xvfb-run -s \"-screen 0 1024x768x24\" pub run --enable-experiment=non-nullable test --preset travis -x phantomjs --total-shards 5 --shard-index 2`"
+    runs-on: ubuntu-latest
+    steps:
+      - name: Cache Pub hosted dependencies
+        uses: actions/cache@v2
+        with:
+          path: "~/.pub-cache/hosted"
+          key: "os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test;commands:command_2"
+          restore-keys: |
+            os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test
+            os:ubuntu-latest;pub-cache-hosted;dart:dev
+            os:ubuntu-latest;pub-cache-hosted
+            os:ubuntu-latest
+      - uses: cedx/setup-dart@v2
+        with:
+          release-channel: dev
+      - run: dart --version
+      - uses: actions/checkout@v2
+      - env:
+          PKGS: pkgs/test
+          TRAVIS_OS_NAME: linux
+        run: tool/ci.sh command_2
+  job_006:
+    name: "OS: linux; SDK: dev; PKG: pkgs/test; TASKS: `xvfb-run -s \"-screen 0 1024x768x24\" pub run --enable-experiment=non-nullable test --preset travis -x phantomjs --total-shards 5 --shard-index 3`"
+    runs-on: ubuntu-latest
+    steps:
+      - name: Cache Pub hosted dependencies
+        uses: actions/cache@v2
+        with:
+          path: "~/.pub-cache/hosted"
+          key: "os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test;commands:command_3"
+          restore-keys: |
+            os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test
+            os:ubuntu-latest;pub-cache-hosted;dart:dev
+            os:ubuntu-latest;pub-cache-hosted
+            os:ubuntu-latest
+      - uses: cedx/setup-dart@v2
+        with:
+          release-channel: dev
+      - run: dart --version
+      - uses: actions/checkout@v2
+      - env:
+          PKGS: pkgs/test
+          TRAVIS_OS_NAME: linux
+        run: tool/ci.sh command_3
+  job_007:
+    name: "OS: linux; SDK: dev; PKG: pkgs/test; TASKS: `xvfb-run -s \"-screen 0 1024x768x24\" pub run --enable-experiment=non-nullable test --preset travis -x phantomjs --total-shards 5 --shard-index 4`"
+    runs-on: ubuntu-latest
+    steps:
+      - name: Cache Pub hosted dependencies
+        uses: actions/cache@v2
+        with:
+          path: "~/.pub-cache/hosted"
+          key: "os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test;commands:command_4"
+          restore-keys: |
+            os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test
+            os:ubuntu-latest;pub-cache-hosted;dart:dev
+            os:ubuntu-latest;pub-cache-hosted
+            os:ubuntu-latest
+      - uses: cedx/setup-dart@v2
+        with:
+          release-channel: dev
+      - run: dart --version
+      - uses: actions/checkout@v2
+      - env:
+          PKGS: pkgs/test
+          TRAVIS_OS_NAME: linux
+        run: tool/ci.sh command_4
+  job_008:
+    name: "OS: linux; SDK: dev; PKG: pkgs/test_api; TASKS: `pub run --enable-experiment=non-nullable test --preset travis -x browser`"
+    runs-on: ubuntu-latest
+    steps:
+      - name: Cache Pub hosted dependencies
+        uses: actions/cache@v2
+        with:
+          path: "~/.pub-cache/hosted"
+          key: "os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test_api;commands:command_5"
+          restore-keys: |
+            os:ubuntu-latest;pub-cache-hosted;dart:dev;packages:pkgs/test_api
+            os:ubuntu-latest;pub-cache-hosted;dart:dev
+            os:ubuntu-latest;pub-cache-hosted
+            os:ubuntu-latest
+      - uses: cedx/setup-dart@v2
+        with:
+          release-channel: dev
+      - run: dart --version
+      - uses: actions/checkout@v2
+      - env:
+          PKGS: pkgs/test_api
+          TRAVIS_OS_NAME: linux
+        run: tool/ci.sh command_5
diff --git a/.travis.yml b/.travis.yml
index 2e503fb..fd7be10 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,4 +1,4 @@
-# Created with package:mono_repo v3.0.0
+# Created with package:mono_repo v3.1.0
 language: dart
 
 # Custom configuration
@@ -11,55 +11,54 @@
 
 jobs:
   include:
-    - stage: mono_repo_self_validate
+    - stage: analyze_and_format
       name: mono_repo self validate
       os: linux
-      script: "pub global activate mono_repo 3.0.0 && pub global run mono_repo travis --validate"
+      script: "pub global activate mono_repo 3.1.0 && pub global run mono_repo generate --validate"
     - stage: analyze_and_format
       name: "SDK: dev; PKGS: pkgs/test, pkgs/test_api, pkgs/test_core; TASKS: [`dartfmt -n --set-exit-if-changed .`, `dartanalyzer --enable-experiment=non-nullable --fatal-infos --fatal-warnings .`]"
       dart: dev
       os: linux
       env: PKGS="pkgs/test pkgs/test_api pkgs/test_core"
-      script: tool/travis.sh dartfmt dartanalyzer
+      script: tool/ci.sh dartfmt dartanalyzer
     - stage: unit_test
       name: "SDK: dev; PKG: pkgs/test; TASKS: `xvfb-run -s \"-screen 0 1024x768x24\" pub run --enable-experiment=non-nullable test --preset travis -x phantomjs --total-shards 5 --shard-index 0`"
       dart: dev
       os: linux
       env: PKGS="pkgs/test"
-      script: tool/travis.sh command_0
+      script: tool/ci.sh command_0
     - stage: unit_test
       name: "SDK: dev; PKG: pkgs/test; TASKS: `xvfb-run -s \"-screen 0 1024x768x24\" pub run --enable-experiment=non-nullable test --preset travis -x phantomjs --total-shards 5 --shard-index 1`"
       dart: dev
       os: linux
       env: PKGS="pkgs/test"
-      script: tool/travis.sh command_1
+      script: tool/ci.sh command_1
     - stage: unit_test
       name: "SDK: dev; PKG: pkgs/test; TASKS: `xvfb-run -s \"-screen 0 1024x768x24\" pub run --enable-experiment=non-nullable test --preset travis -x phantomjs --total-shards 5 --shard-index 2`"
       dart: dev
       os: linux
       env: PKGS="pkgs/test"
-      script: tool/travis.sh command_2
+      script: tool/ci.sh command_2
     - stage: unit_test
       name: "SDK: dev; PKG: pkgs/test; TASKS: `xvfb-run -s \"-screen 0 1024x768x24\" pub run --enable-experiment=non-nullable test --preset travis -x phantomjs --total-shards 5 --shard-index 3`"
       dart: dev
       os: linux
       env: PKGS="pkgs/test"
-      script: tool/travis.sh command_3
+      script: tool/ci.sh command_3
     - stage: unit_test
       name: "SDK: dev; PKG: pkgs/test; TASKS: `xvfb-run -s \"-screen 0 1024x768x24\" pub run --enable-experiment=non-nullable test --preset travis -x phantomjs --total-shards 5 --shard-index 4`"
       dart: dev
       os: linux
       env: PKGS="pkgs/test"
-      script: tool/travis.sh command_4
+      script: tool/ci.sh command_4
     - stage: unit_test
       name: "SDK: dev; PKG: pkgs/test_api; TASKS: `pub run --enable-experiment=non-nullable test --preset travis -x browser`"
       dart: dev
       os: linux
       env: PKGS="pkgs/test_api"
-      script: tool/travis.sh command_5
+      script: tool/ci.sh command_5
 
 stages:
-  - mono_repo_self_validate
   - analyze_and_format
   - unit_test
 
@@ -70,4 +69,4 @@
 
 cache:
   directories:
-    - "$HOME/.pub-cache"
+    - $HOME/.pub-cache
diff --git a/mono_repo.yaml b/mono_repo.yaml
index 266bfe4..a1d69da 100644
--- a/mono_repo.yaml
+++ b/mono_repo.yaml
@@ -1,5 +1,10 @@
 # See with https://github.com/dart-lang/mono_repo for details on this file
-self_validate: true
+self_validate: analyze_and_format
+
+github:
+  env:
+    FORCE_TEST_EXIT: true
+
 travis:
   addons:
     chrome: stable
diff --git a/tool/travis.sh b/tool/ci.sh
similarity index 98%
rename from tool/travis.sh
rename to tool/ci.sh
index 765947a..c6618c5 100755
--- a/tool/travis.sh
+++ b/tool/ci.sh
@@ -1,5 +1,5 @@
 #!/bin/bash
-# Created with package:mono_repo v3.0.0
+# Created with package:mono_repo v3.1.0
 
 # Support built in commands on windows out of the box.
 function pub() {
diff --git a/tool/mono_repo_self_validate.sh b/tool/mono_repo_self_validate.sh
deleted file mode 100755
index ec70a28..0000000
--- a/tool/mono_repo_self_validate.sh
+++ /dev/null
@@ -1,15 +0,0 @@
-#!/bin/bash
-# Created with package:mono_repo v2.5.0
-
-# Support built in commands on windows out of the box.
-function pub {
-       if [[ $TRAVIS_OS_NAME == "windows" ]]; then
-        command pub.bat "$@"
-    else
-        command pub "$@"
-    fi
-}
-
-set -v -e
-pub global activate mono_repo 2.5.0
-pub global run mono_repo travis --validate