Skip to content

Commit

Permalink
Merge branch 'dart-lang:master' into feat/cancellation
Browse files Browse the repository at this point in the history
  • Loading branch information
SamJakob authored Oct 1, 2023
2 parents f6ac341 + 88ec75e commit 918fe2d
Show file tree
Hide file tree
Showing 50 changed files with 9,402 additions and 5,396 deletions.
8 changes: 3 additions & 5 deletions .github/workflows/cronet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
run:
working-directory: pkgs/cronet_http
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2
with:
# TODO: Change to 'stable' when a release version of flutter
Expand All @@ -48,16 +48,14 @@ jobs:
name: "Build and test"
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: '17'
- uses: subosito/flutter-action@v2
with:
# TODO: Change to 'stable' when a release version of flutter
# pins version 1.21.1 or later of 'package:test'
channel: 'master'
channel: 'stable'
- name: Run tests
uses: reactivecircus/android-emulator-runner@v2
with:
Expand Down
13 changes: 10 additions & 3 deletions .github/workflows/cupertino.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,22 @@ jobs:
run:
working-directory: pkgs/cupertino_http
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2
with:
channel: 'stable'
- id: install
name: Install dependencies
run: flutter pub get
- name: Check formatting
run: dart format --output=none --set-exit-if-changed .
# Don't lint the generated file native_cupertino_bindings.dart
# This approach is simpler than using `find` and excluding that file
# because `dart format` also excludes other file e.g. ones in
# directories start with '.'.
run: >
mv lib/src/native_cupertino_bindings.dart lib/src/native_cupertino_bindings.tmp &&
dart format --output=none --set-exit-if-changed . &&
mv lib/src/native_cupertino_bindings.tmp lib/src/native_cupertino_bindings.dart
if: always() && steps.install.outcome == 'success'
- name: Analyze code
run: flutter analyze --fatal-infos
Expand All @@ -56,7 +63,7 @@ jobs:
run:
working-directory: pkgs/cupertino_http/example
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: futureware-tech/simulator-action@v2
with:
model: 'iPhone 8'
Expand Down
66 changes: 33 additions & 33 deletions .github/workflows/dart.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions .github/workflows/java.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
run:
working-directory: pkgs/java_http
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2
with:
channel: 'stable'
Expand All @@ -55,7 +55,7 @@ jobs:
working-directory: pkgs/java_http

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2
with:
channel: 'stable'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pull_request_label.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
pull-requests: write
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@0967ca812e7fdc8f5f71402a1b486d5bd061fe20
- uses: actions/labeler@ac9175f8a1f3625fd0d4fb234536d26811351594
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
sync-labels: true
6 changes: 2 additions & 4 deletions pkgs/cronet_http/.gitattributes
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
# pigeon generated code
lib/src/messages.dart linguist-generated
android/src/main/java/io/flutter/plugins/cronet_http/Messages.java linguist-generated

# jnigen generated code
lib/src/jni/jni_bindings.dart linguist-generated
12 changes: 12 additions & 0 deletions pkgs/cronet_http/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,15 @@
## 0.4.0-jni

* Use more efficient operations when copying bytes between Java and Dart.

## 0.3.0-jni

* Switch to using `package:jnigen` for bindings to Cronet
* Support for running in background isolates.
* **Breaking Change:** `CronetEngine.build()` returns a `CronetEngine` rather
than a `Future<CronetEngine>` and `CronetClient.fromCronetEngineFuture()`
has been removed because it is no longer necessary.

## 0.2.2

* Require Dart 3.0
Expand Down
11 changes: 10 additions & 1 deletion pkgs/cronet_http/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,21 @@ android {

sourceSets {
main.java.srcDirs += 'src/main/kotlin'
main.java.srcDirs += 'src/main/java'
}

defaultConfig {
minSdkVersion 16
}

defaultConfig {
consumerProguardFiles 'consumer-rules.pro'
}

buildTypes {
release {
minifyEnabled false
}
}
}

dependencies {
Expand Down
Loading

0 comments on commit 918fe2d

Please sign in to comment.