mirror of
https://github.com/flutter-webrtc/flutter-webrtc
synced 2025-07-07 21:55:37 +00:00
fix github actions. (#1357)
* update. * Delete libwebrtc.aar * update. * fix compiler for linux. * add workflow for windows/macos. * add workflow for windows/macos/linux/android/ios/web. * update.
This commit is contained in:
132
.github/workflows/build.yml
vendored
132
.github/workflows/build.yml
vendored
@ -7,34 +7,130 @@ on:
|
||||
branches: [ main ]
|
||||
|
||||
jobs:
|
||||
test:
|
||||
name: Test on ${{ matrix.os }}
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-latest]
|
||||
dart-format-and-analyze-check:
|
||||
name: Dart Format Check
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: '12.x'
|
||||
- uses: subosito/flutter-action@v1
|
||||
- uses: actions/checkout@v2
|
||||
- uses: subosito/flutter-action@v2
|
||||
with:
|
||||
flutter-version: '3.7.12'
|
||||
channel: 'stable'
|
||||
cache: true
|
||||
- run: flutter packages get
|
||||
- run: flutter format lib/ test/ --set-exit-if-changed
|
||||
- run: flutter pub run import_sorter:main --no-comments --exit-if-changed
|
||||
- run: flutter analyze
|
||||
- run: flutter test
|
||||
- name: Start Web Build
|
||||
working-directory: ./example
|
||||
run: flutter build web --release
|
||||
- name: Start android Build
|
||||
- name: Install project dependencies
|
||||
run: flutter pub get
|
||||
- name: Dart Format Check
|
||||
run: dart format lib/ test/ --set-exit-if-changed
|
||||
- name: Import Sorter Check
|
||||
run: flutter pub run import_sorter:main --no-comments --exit-if-changed
|
||||
- name: Dart Analyze Check
|
||||
run: flutter analyze
|
||||
- name: Dart Test Check
|
||||
run: flutter test
|
||||
|
||||
build-for-android:
|
||||
name: Build for Flutter Android
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: '12.x'
|
||||
- uses: actions/checkout@v2
|
||||
- uses: subosito/flutter-action@v2
|
||||
with:
|
||||
channel: 'stable'
|
||||
- name: Install project dependencies
|
||||
run: flutter pub get
|
||||
- name: Start Android Build
|
||||
working-directory: ./example
|
||||
run: flutter build apk
|
||||
|
||||
build-for-ios:
|
||||
name: Build for Flutter iOS
|
||||
runs-on: macos-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: subosito/flutter-action@v2
|
||||
with:
|
||||
channel: 'stable'
|
||||
- name: Install project dependencies
|
||||
run: flutter pub get
|
||||
- name: Build for iOS
|
||||
working-directory: ./example
|
||||
run: flutter build ios --release --no-codesign
|
||||
|
||||
build-for-windows:
|
||||
name: Build for flutter Windows
|
||||
runs-on: windows-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: subosito/flutter-action@v1
|
||||
with:
|
||||
channel: 'stable'
|
||||
- name: Install project dependencies
|
||||
run: flutter pub get
|
||||
- name: Build for windows
|
||||
working-directory: ./example
|
||||
run: flutter build windows --release
|
||||
|
||||
build-for-macos:
|
||||
name: Build for flutter macOS
|
||||
runs-on: macos-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: subosito/flutter-action@v1
|
||||
with:
|
||||
channel: 'stable'
|
||||
- name: Install project dependencies
|
||||
run: flutter pub get
|
||||
- name: Build for windows
|
||||
working-directory: ./example
|
||||
run: flutter build macos --release
|
||||
|
||||
build-for-linux:
|
||||
name: Build for Flutter Linux
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: '12.x'
|
||||
- uses: actions/checkout@v2
|
||||
- uses: subosito/flutter-action@v2
|
||||
with:
|
||||
channel: 'stable'
|
||||
- name: Install project dependencies
|
||||
run: flutter pub get
|
||||
- name: Install ninja-build libgtk-3-dev
|
||||
run: sudo apt-get install -y ninja-build libgtk-3-dev
|
||||
- name: Start Linux Build
|
||||
working-directory: ./example
|
||||
run: flutter build linux
|
||||
|
||||
build-for-web:
|
||||
name: Build for Flutter Web
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: '12.x'
|
||||
- uses: actions/checkout@v2
|
||||
- uses: subosito/flutter-action@v2
|
||||
with:
|
||||
channel: 'stable'
|
||||
- name: Install project dependencies
|
||||
run: flutter pub get
|
||||
- name: Start Web Build
|
||||
working-directory: ./example
|
||||
run: flutter build web
|
1
.gitignore
vendored
1
.gitignore
vendored
@ -6,7 +6,6 @@ pubspec.lock
|
||||
example/ios/Podfile.lock
|
||||
GeneratedPluginRegistrant.java
|
||||
example/android/.gradle
|
||||
example/android/gradle*
|
||||
WorkspaceSettings.xcsettings
|
||||
example/.flutter-plugins
|
||||
example/android/local.properties
|
||||
|
Binary file not shown.
3
example/android/gradle.properties
Normal file
3
example/android/gradle.properties
Normal file
@ -0,0 +1,3 @@
|
||||
org.gradle.jvmargs=-Xmx1536M
|
||||
android.useAndroidX=true
|
||||
android.enableJetifier=true
|
5
example/android/gradle/wrapper/gradle-wrapper.properties
vendored
Normal file
5
example/android/gradle/wrapper/gradle-wrapper.properties
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-all.zip
|
Reference in New Issue
Block a user