Skip to content

Commit d209112

Browse files
committed
💥 Upgrade to Flutter version 3.24
Migration Guide: The source have been updated to work with the latest version of Flutter, including upgrading from Gradle v7 to v8. Make sure that you are on the latest version on Flutter before upgrading to this version.
1 parent 6afdfdc commit d209112

File tree

96 files changed

+1220
-850
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

96 files changed

+1220
-850
lines changed

.gitignore

Lines changed: 25 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,29 @@
1+
# Miscellaneous
2+
*.class
3+
*.log
4+
*.pyc
5+
*.swp
16
.DS_Store
2-
.dart_tool/
7+
.atom/
8+
.buildlog/
9+
.history
10+
.svn/
11+
migrate_working_dir/
312

4-
.packages
5-
.pub/
13+
# IntelliJ related
14+
*.iml
15+
*.ipr
16+
*.iws
17+
.idea/
618

7-
build/
19+
# The .vscode folder contains launch configuration and tasks you configure in
20+
# VS Code which you may wish to be included in version control, so this line
21+
# is commented out by default.
22+
#.vscode/
823

9-
.idea
24+
# Flutter/Dart/Pub related
25+
# Libraries should not include pubspec.lock, per https://dart.dev/guides/libraries/private-files#pubspeclock.
26+
/pubspec.lock
27+
**/doc/api/
28+
.dart_tool/
29+
build/

android/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,4 @@
66
.DS_Store
77
/build
88
/captures
9+
.cxx

android/build.gradle

Lines changed: 40 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,69 @@
1-
group 'com.linusu.flutter_web_auth'
2-
version '1.0-SNAPSHOT'
1+
group = "com.linusu.flutter_web_auth"
2+
version = "1.0-SNAPSHOT"
33

44
buildscript {
5-
ext.kotlin_version = '1.5.31'
5+
ext.kotlin_version = "1.8.22"
66
repositories {
77
google()
88
mavenCentral()
99
}
1010

1111
dependencies {
12-
classpath 'com.android.tools.build:gradle:7.0.3'
13-
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
12+
classpath("com.android.tools.build:gradle:8.1.0")
13+
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version")
1414
}
1515
}
1616

17-
rootProject.allprojects {
17+
allprojects {
1818
repositories {
1919
google()
2020
mavenCentral()
2121
}
2222
}
2323

24-
apply plugin: 'com.android.library'
25-
apply plugin: 'kotlin-android'
24+
apply plugin: "com.android.library"
25+
apply plugin: "kotlin-android"
2626

2727
android {
28-
compileSdkVersion 31
28+
if (project.android.hasProperty("namespace")) {
29+
namespace = "com.linusu.flutter_web_auth"
30+
}
31+
32+
compileSdk = 34
33+
34+
compileOptions {
35+
sourceCompatibility = JavaVersion.VERSION_1_8
36+
targetCompatibility = JavaVersion.VERSION_1_8
37+
}
38+
39+
kotlinOptions {
40+
jvmTarget = JavaVersion.VERSION_1_8
41+
}
2942

3043
sourceSets {
31-
main.java.srcDirs += 'src/main/kotlin'
44+
main.java.srcDirs += "src/main/kotlin"
45+
test.java.srcDirs += "src/test/kotlin"
3246
}
47+
3348
defaultConfig {
34-
minSdkVersion 16
35-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
36-
}
37-
lintOptions {
38-
disable 'InvalidPackage'
49+
minSdk = 21
3950
}
4051

4152
dependencies {
42-
implementation 'androidx.browser:browser:1.3.0'
53+
implementation("androidx.browser:browser:1.8.0")
54+
testImplementation("org.jetbrains.kotlin:kotlin-test")
55+
testImplementation("org.mockito:mockito-core:5.0.0")
4356
}
44-
}
4557

46-
dependencies {
47-
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
58+
testOptions {
59+
unitTests.all {
60+
useJUnitPlatform()
61+
62+
testLogging {
63+
events "passed", "skipped", "failed", "standardOut", "standardError"
64+
outputs.upToDateWhen {false}
65+
showStandardStreams = true
66+
}
67+
}
68+
}
4869
}

example/.gitignore

Lines changed: 15 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -8,69 +8,36 @@
88
.buildlog/
99
.history
1010
.svn/
11+
migrate_working_dir/
1112

1213
# IntelliJ related
1314
*.iml
1415
*.ipr
1516
*.iws
1617
.idea/
1718

18-
# Visual Studio Code related
19-
.vscode/
19+
# The .vscode folder contains launch configuration and tasks you configure in
20+
# VS Code which you may wish to be included in version control, so this line
21+
# is commented out by default.
22+
#.vscode/
2023

2124
# Flutter/Dart/Pub related
2225
**/doc/api/
26+
**/ios/Flutter/.last_build_id
2327
.dart_tool/
2428
.flutter-plugins
2529
.flutter-plugins-dependencies
26-
.packages
2730
.pub-cache/
2831
.pub/
29-
build/
30-
flutter_*.png
31-
linked_*.ds
32-
unlinked.ds
33-
unlinked_spec.ds
32+
/build/
3433

35-
# Android related
36-
**/android/**/gradle-wrapper.jar
37-
**/android/.gradle
38-
**/android/captures/
39-
**/android/gradlew
40-
**/android/gradlew.bat
41-
**/android/local.properties
42-
**/android/**/GeneratedPluginRegistrant.java
34+
# Symbolication related
35+
app.*.symbols
4336

44-
# iOS/XCode related
45-
**/ios/**/*.mode1v3
46-
**/ios/**/*.mode2v3
47-
**/ios/**/*.moved-aside
48-
**/ios/**/*.pbxuser
49-
**/ios/**/*.perspectivev3
50-
**/ios/**/*sync/
51-
**/ios/**/.sconsign.dblite
52-
**/ios/**/.tags*
53-
**/ios/**/.vagrant/
54-
**/ios/**/DerivedData/
55-
**/ios/**/Icon?
56-
**/ios/**/Pods/
57-
**/ios/**/.symlinks/
58-
**/ios/**/profile
59-
**/ios/**/xcuserdata
60-
**/ios/.generated/
61-
**/ios/Flutter/App.framework
62-
**/ios/Flutter/Flutter.framework
63-
**/ios/Flutter/Generated.xcconfig
64-
**/ios/Flutter/app.flx
65-
**/ios/Flutter/app.zip
66-
**/ios/Flutter/flutter_assets/
67-
**/ios/Flutter/flutter_export_environment.sh
68-
**/ios/ServiceDefinitions.json
69-
**/ios/Runner/GeneratedPluginRegistrant.*
37+
# Obfuscation related
38+
app.*.map.json
7039

71-
# Exceptions to above rules.
72-
!**/ios/**/default.mode1v3
73-
!**/ios/**/default.mode2v3
74-
!**/ios/**/default.pbxuser
75-
!**/ios/**/default.perspectivev3
76-
!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages
40+
# Android Studio will place build artifacts here
41+
/android/app/debug
42+
/android/app/profile
43+
/android/app/release

example/.metadata

Lines changed: 0 additions & 10 deletions
This file was deleted.

example/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@ This project is a starting point for a Flutter application.
88

99
A few resources to get you started if this is your first Flutter project:
1010

11-
- [Lab: Write your first Flutter app](https://flutter.io/docs/get-started/codelab)
12-
- [Cookbook: Useful Flutter samples](https://flutter.io/docs/cookbook)
11+
- [Lab: Write your first Flutter app](https://docs.flutter.dev/get-started/codelab)
12+
- [Cookbook: Useful Flutter samples](https://docs.flutter.dev/cookbook)
1313

14-
For help getting started with Flutter, view our
15-
[online documentation](https://flutter.io/docs), which offers tutorials,
14+
For help getting started with Flutter development, view the
15+
[online documentation](https://docs.flutter.dev/), which offers tutorials,
1616
samples, guidance on mobile development, and a full API reference.

example/analysis_options.yaml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# This file configures the analyzer, which statically analyzes Dart code to
2+
# check for errors, warnings, and lints.
3+
#
4+
# The issues identified by the analyzer are surfaced in the UI of Dart-enabled
5+
# IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be
6+
# invoked from the command line by running `flutter analyze`.
7+
8+
# The following line activates a set of recommended lints for Flutter apps,
9+
# packages, and plugins designed to encourage good coding practices.
10+
include: package:flutter_lints/flutter.yaml
11+
12+
linter:
13+
# The lint rules applied to this project can be customized in the
14+
# section below to disable rules from the `package:flutter_lints/flutter.yaml`
15+
# included above or to enable additional rules. A list of all available lints
16+
# and their documentation is published at https://dart.dev/lints.
17+
#
18+
# Instead of disabling a lint rule for the entire project in the
19+
# section below, it can also be suppressed for a single line of code
20+
# or a specific dart file by using the `// ignore: name_of_lint` and
21+
# `// ignore_for_file: name_of_lint` syntax on the line or in the file
22+
# producing the lint.
23+
rules:
24+
# avoid_print: false # Uncomment to disable the `avoid_print` rule
25+
# prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule
26+
27+
# Additional information about this file can be found at
28+
# https://dart.dev/guides/language/analysis-options

example/android/.gitignore

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
gradle-wrapper.jar
2+
/.gradle
3+
/captures/
4+
/gradlew
5+
/gradlew.bat
6+
/local.properties
7+
GeneratedPluginRegistrant.java
8+
9+
# Remember to never publicly share your keystore.
10+
# See https://flutter.dev/to/reference-keystore
11+
key.properties
12+
**/*.keystore
13+
**/*.jks

example/android/.project

Lines changed: 0 additions & 17 deletions
This file was deleted.

example/android/.settings/org.eclipse.buildship.core.prefs

Lines changed: 0 additions & 2 deletions
This file was deleted.

example/android/app/.classpath

Lines changed: 0 additions & 6 deletions
This file was deleted.

example/android/app/.project

Lines changed: 0 additions & 23 deletions
This file was deleted.

example/android/app/.settings/org.eclipse.buildship.core.prefs

Lines changed: 0 additions & 2 deletions
This file was deleted.

0 commit comments

Comments
 (0)