forked from firebase/flutterfire
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(firebase_core): v1 rework (firebase#7) (firebase#2890)
Co-authored-by: ehesp <[email protected]> Co-authored-by: Kirsty Williams <[email protected]> Co-authored-by: Helena Ford <[email protected]> Co-authored-by: Kirsty Williams <[email protected]> Co-authored-by: Greg Hesp <[email protected]>
- Loading branch information
1 parent
d0fa43e
commit 584d0d3
Showing
247 changed files
with
5,231 additions
and
1,907 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,111 @@ | ||
name: all_plugins | ||
|
||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
analyze: | ||
timeout-minutes: 15 | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v1 | ||
with: | ||
fetch-depth: 0 | ||
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: "stable" | ||
- name: "Install Tools" | ||
run: | | ||
pub global activate tuneup | ||
pub global activate melos | ||
echo "::add-path::$HOME/.pub-cache/bin" | ||
- name: "Bootstrap Workspace" | ||
run: melos bootstrap | ||
- name: "Dart Analyze" | ||
run: | | ||
melos exec -c 3 -- \ | ||
tuneup check | ||
- name: "Pub Check" | ||
run: | | ||
melos exec -c 1 --no-private --ignore="*example*" -- \ | ||
pub publish --dry-run | ||
format: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 15 | ||
steps: | ||
- uses: actions/checkout@v1 | ||
with: | ||
fetch-depth: 0 | ||
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: "stable" | ||
- name: "Install Tools" | ||
run: | | ||
pub global activate melos | ||
curl -sL https://github.com/google/google-java-format/releases/download/google-java-format-1.3/google-java-format-1.3-all-deps.jar -o $HOME/google-java-format.jar | ||
echo "::add-path::$HOME/.pub-cache/bin" | ||
- name: "Bootstrap Workspace" | ||
run: melos bootstrap | ||
- name: "Dart" | ||
run: | | ||
melos exec -c 1 -- \ | ||
flutter format . | ||
./.github/workflows/scripts/validate-formatting.sh | ||
- name: "Objective-C" | ||
if: ${{ success() || failure() }} | ||
run: | | ||
melos exec -c 4 --ignore="*platform_interface*" --ignore="*web*" -- \ | ||
find . -maxdepth 3 -name "*.h" -o -name "*.m" -print0 \| xargs -0 clang-format -i --style=Google --verbose | ||
./.github/workflows/scripts/validate-formatting.sh | ||
- name: "Java" | ||
if: ${{ success() || failure() }} | ||
run: | | ||
melos exec -c 4 --ignore="*platform_interface*" --ignore="*web*" -- \ | ||
find . -maxdepth 12 -name "*.java" -print0 \| xargs -0 java -jar $HOME/google-java-format.jar --replace | ||
./.github/workflows/scripts/validate-formatting.sh | ||
build_examples_dart: | ||
timeout-minutes: 15 | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v1 | ||
with: | ||
fetch-depth: 0 | ||
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: "stable" | ||
- name: "Install Tools" | ||
run: | | ||
pub global activate melos | ||
echo "::add-path::$HOME/.pub-cache/bin" | ||
- name: "Bootstrap Workspace" | ||
run: melos bootstrap | ||
- name: "Build Example Snapshots" | ||
run: | | ||
melos exec -c 1 --scope="*example*" -- \ | ||
flutter build aot | ||
test: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 15 | ||
steps: | ||
- uses: actions/checkout@v1 | ||
with: | ||
fetch-depth: 0 | ||
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: "stable" | ||
- name: "Install Tools" | ||
run: | | ||
pub global activate melos | ||
echo "::add-path::$HOME/.pub-cache/bin" | ||
- name: "Bootstrap Workspace" | ||
run: melos bootstrap | ||
- name: "Flutter Test" | ||
run: | | ||
melos exec -c 3 --dir-exists=test --ignore="*example*" --ignore="*web*" -- \ | ||
flutter test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
name: cancel_previous | ||
on: [push] | ||
jobs: | ||
cancel: | ||
name: "Cancel Previous Runs" | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 3 | ||
steps: | ||
- uses: styfle/[email protected] | ||
with: | ||
# TODO(Salakar): Update ids once on master. | ||
workflow_id: 1411321,1411322,1414417,1414454,1414624,1414626,1414627 | ||
access_token: ${{ github.token }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,115 @@ | ||
name: firebase_auth | ||
|
||
on: | ||
pull_request: | ||
paths: | ||
- "packages/firebase_core/**" | ||
- "packages/firebase_auth/**" | ||
- ".github/workflows/firebase_auth.yaml" | ||
push: | ||
branches: | ||
- master | ||
|
||
env: | ||
FLUTTERFIRE_PLUGIN_SCOPE: "*firebase_auth*" | ||
FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE: "*firebase_auth_example*" | ||
|
||
jobs: | ||
android: | ||
runs-on: macos-latest | ||
timeout-minutes: 30 | ||
steps: | ||
- uses: actions/checkout@v1 | ||
with: | ||
fetch-depth: 0 | ||
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: "stable" | ||
- name: "Install Tools" | ||
run: | | ||
pub global activate melos | ||
echo "::add-path::$HOME/.pub-cache/bin" | ||
- name: "Bootstrap Workspace" | ||
run: melos bootstrap | ||
- name: "Build Example" | ||
run: | | ||
melos exec -c 1 --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" -- \ | ||
flutter build apk | ||
- name: Download Emulator Image | ||
run: | | ||
echo "y" | $ANDROID_HOME/tools/bin/sdkmanager --install "system-images;android-28;google_apis;x86_64" | ||
echo "no" | $ANDROID_HOME/tools/bin/avdmanager create avd --force --name TestingAVD --device "Nexus 5X" -k 'system-images;android-28;google_apis;x86_64' -g google_apis | ||
$ANDROID_HOME/emulator/emulator -list-avds | ||
- name: Start Android Emulator | ||
timeout-minutes: 15 | ||
continue-on-error: true | ||
run: | | ||
echo "Starting emulator" | ||
nohup $ANDROID_HOME/emulator/emulator -avd TestingAVD -no-audio -no-snapshot -no-window -no-boot-anim & | ||
$ANDROID_HOME/platform-tools/adb wait-for-device shell 'while [[ -z $(getprop sys.boot_completed | tr -d '\r') ]]; do sleep 1; done' | ||
$ANDROID_HOME/platform-tools/adb devices | ||
$ANDROID_HOME/platform-tools/adb shell settings put global window_animation_scale 0.0 | ||
$ANDROID_HOME/platform-tools/adb shell settings put global transition_animation_scale 0.0 | ||
$ANDROID_HOME/platform-tools/adb shell settings put global animator_duration_scale 0.0 | ||
echo "Emulator started" | ||
flutter emulators | ||
- name: "Drive Example" | ||
run: | | ||
melos exec -c 1 --fail-fast --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" --dir-exists=test_driver -- \ | ||
flutter drive --no-pub --target=./test_driver/MELOS_PARENT_PACKAGE_NAME_e2e.dart | ||
ios: | ||
runs-on: macos-latest | ||
timeout-minutes: 30 | ||
steps: | ||
- uses: actions/checkout@v1 | ||
with: | ||
fetch-depth: 0 | ||
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: "stable" | ||
- name: "Install Tools" | ||
run: | | ||
pub global activate melos | ||
echo "::add-path::$HOME/.pub-cache/bin" | ||
- name: "Bootstrap Workspace" | ||
run: melos bootstrap | ||
- name: "Build Example" | ||
run: | | ||
melos exec -c 1 --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" -- \ | ||
flutter build ios --no-codesign | ||
- name: "Boot Simulator" | ||
run: xcrun simctl boot "iPhone 11" | ||
- name: "Drive Example" | ||
run: | | ||
melos exec -c 1 --fail-fast --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" --dir-exists=test_driver -- \ | ||
flutter drive --no-pub --target=./test_driver/MELOS_PARENT_PACKAGE_NAME_e2e.dart | ||
web: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 15 | ||
steps: | ||
- uses: actions/checkout@v1 | ||
with: | ||
fetch-depth: 0 | ||
- uses: subosito/flutter-action@v1 | ||
with: | ||
# https://github.com/subosito/flutter-action/issues/37 | ||
channel: "beta" | ||
- name: "Install Tools" | ||
run: | | ||
pub global activate melos | ||
flutter config --enable-web | ||
echo "::add-path::$HOME/.pub-cache/bin" | ||
- name: "Bootstrap Workspace" | ||
run: melos bootstrap | ||
- name: "Build Example" | ||
run: | | ||
melos exec -c 1 --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" --dir-exists=web -- \ | ||
flutter build web | ||
- name: "Drive Example" | ||
run: | | ||
melos clean && melos bootstrap | ||
chromedriver --port=4444 & | ||
melos exec -c 1 --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" --dir-exists=web -- \ | ||
flutter drive --release --no-pub --verbose-system-logs --browser-name=chrome --target=./test_driver/MELOS_PARENT_PACKAGE_NAME_e2e.dart |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,126 @@ | ||
name: firebase_core | ||
|
||
on: | ||
pull_request: | ||
paths: | ||
- "packages/firebase_core/**" | ||
- ".github/workflows/firebase_core.yaml" | ||
push: | ||
branches: | ||
- master | ||
|
||
env: | ||
FLUTTERFIRE_PLUGIN_SCOPE: "*firebase_core*" | ||
FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE: "*firebase_core_example*" | ||
|
||
jobs: | ||
android: | ||
runs-on: macos-latest | ||
timeout-minutes: 30 | ||
steps: | ||
- uses: actions/checkout@v1 | ||
with: | ||
fetch-depth: 0 | ||
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: "stable" | ||
- name: "Install Tools" | ||
run: | | ||
pub global activate melos | ||
echo "::add-path::$HOME/.pub-cache/bin" | ||
- name: "Bootstrap Workspace" | ||
run: melos bootstrap | ||
- name: "Build Example" | ||
run: | | ||
melos exec -c 1 --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" -- \ | ||
flutter build apk | ||
- name: Download Emulator Image | ||
run: | | ||
echo "y" | $ANDROID_HOME/tools/bin/sdkmanager --install "system-images;android-28;google_apis;x86_64" | ||
echo "no" | $ANDROID_HOME/tools/bin/avdmanager create avd --force --name TestingAVD --device "Nexus 5X" -k 'system-images;android-28;google_apis;x86_64' -g google_apis | ||
$ANDROID_HOME/emulator/emulator -list-avds | ||
- name: Start Android Emulator | ||
timeout-minutes: 15 | ||
continue-on-error: true | ||
run: | | ||
echo "Starting emulator" | ||
nohup $ANDROID_HOME/emulator/emulator -avd TestingAVD -no-audio -no-snapshot -no-window -no-boot-anim & | ||
$ANDROID_HOME/platform-tools/adb wait-for-device shell 'while [[ -z $(getprop sys.boot_completed | tr -d '\r') ]]; do sleep 1; done' | ||
$ANDROID_HOME/platform-tools/adb devices | ||
$ANDROID_HOME/platform-tools/adb shell settings put global window_animation_scale 0.0 | ||
$ANDROID_HOME/platform-tools/adb shell settings put global transition_animation_scale 0.0 | ||
$ANDROID_HOME/platform-tools/adb shell settings put global animator_duration_scale 0.0 | ||
echo "Emulator started" | ||
flutter emulators | ||
- name: "Drive Example" | ||
run: | | ||
melos exec -c 1 --fail-fast --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" --dir-exists=test_driver -- \ | ||
flutter drive --no-pub --target=./test_driver/MELOS_PARENT_PACKAGE_NAME_e2e.dart | ||
apple: | ||
runs-on: macos-latest | ||
timeout-minutes: 35 | ||
steps: | ||
- uses: actions/checkout@v1 | ||
with: | ||
fetch-depth: 0 | ||
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: "dev" | ||
- name: "Install Tools" | ||
run: | | ||
pub global activate melos | ||
echo "::add-path::$HOME/.pub-cache/bin" | ||
flutter config --enable-macos-desktop | ||
flutter devices | ||
- name: "Bootstrap Workspace" | ||
run: melos bootstrap | ||
- name: "Build iOS Example" | ||
run: | | ||
melos exec -c 1 --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" -- \ | ||
flutter build ios --no-codesign | ||
- name: "Boot Simulator" | ||
run: xcrun simctl boot "iPhone 11" | ||
- name: "Drive iOS Example" | ||
run: | | ||
melos exec -c 1 --fail-fast --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" --dir-exists=test_driver -- \ | ||
flutter drive -d \"iPhone 11\" --no-pub --target=./test_driver/MELOS_PARENT_PACKAGE_NAME_e2e.dart | ||
- name: "Shutdown Simulator" | ||
run: xcrun simctl shutdown "iPhone 11" | ||
- name: "Build MacOS Example" | ||
run: | | ||
melos exec -c 1 --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" -- \ | ||
flutter build macos | ||
- name: "Drive MacOS Example" | ||
run: | | ||
melos exec -c 1 --fail-fast --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" --dir-exists=test_driver -- \ | ||
flutter drive -d macos --no-pub --target=./test_driver/MELOS_PARENT_PACKAGE_NAME_e2e.dart | ||
web: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 15 | ||
steps: | ||
- uses: actions/checkout@v1 | ||
with: | ||
fetch-depth: 0 | ||
- uses: subosito/flutter-action@v1 | ||
with: | ||
# https://github.com/subosito/flutter-action/issues/37 | ||
channel: "beta" | ||
- name: "Install Tools" | ||
run: | | ||
pub global activate melos | ||
flutter config --enable-web | ||
echo "::add-path::$HOME/.pub-cache/bin" | ||
- name: "Bootstrap Workspace" | ||
run: melos bootstrap | ||
- name: "Build Example" | ||
run: | | ||
melos exec -c 1 --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" --dir-exists=web -- \ | ||
flutter build web | ||
- name: "Drive Example" | ||
run: | | ||
melos clean && melos bootstrap | ||
chromedriver --port=4444 & | ||
melos exec -c 1 --scope="$FLUTTERFIRE_PLUGIN_SCOPE_EXAMPLE" --dir-exists=web -- \ | ||
flutter drive --release --no-pub --verbose-system-logs --browser-name=chrome --target=./test_driver/MELOS_PARENT_PACKAGE_NAME_e2e.dart |
Oops, something went wrong.