Skip to content

Commit b109109

Browse files
authored
Release 0.3.0 (#5)
* Remove producer install tasks because v2023.1.1.beta gradle plugin handles installation through the compiler plugin. * Removed unused function. * Add mavenLocal to gradle files for easier integration testing. Add lookup function to get klutter BOM from root/klutter.yaml also for easier integration testing and project generation using kommand. * Move findKlutterBomVersion to task. * If version is quoted, then remove them in findKlutterBomVersion. * Add missing @controller annotation in platform example code. Update MyApp example code to use the 2023.1.1 klutter code. Bump Kotlin to 1.8.20 for Android apps. * Update readme. * Bump gradle-wrapper to 7.2. Add extra FAQ. * Add FlutterEngine.xcframework to the root/ios podspec file. Copy FlutterEngine.xcframework to ios/Klutter, not ios/Klutter/FlutterEngine.xcframework. * Set path to root in generated android build.gradle. Add embedded dependencies in android build.gradle. * KlutterAdaptee is deprecated. Use Event instead. * Remove ios init task because it should only be run when developer platform is an Intel Mac. This can be configured through Gradle build file. * Add change information to CHANGELOG. * Latest flutter-engine-kmp xcframework. * Remove FlutterEngine XCFramework and get the dependencies for both iOS and Android through the platform module. * Add flutter-engine to iosMain sourceSet dependencies. * Remove flutter-engine-android from producer android build.gradle because it is included through embedded dependency. * Make klutter_plugin_loader.gradle.kts smarter to use $root variable in a local path. * Release 0.3.0.
1 parent 46d3dc0 commit b109109

File tree

40 files changed

+409
-1706
lines changed

40 files changed

+409
-1706
lines changed

CHANGELOG.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
11
## 0.3.0
22
* Uses Klutter Gradle v2023.1.1.beta.
3-
* Add Flutter Engine XCFramework to be copied during project initialization.
3+
* Removed producer install tasks because Klutter Gradle v2023.1.1.beta does the installation during gradle build.
44
* Remove widgets in order to scope klutter-dart to dev_dependency (widgets are now found in [klutter-dart-ui](https://github.com/buijs-dev/klutter-dart-ui).
5+
* Embedded gradle-wrapper bumped to version 7.2.
6+
* Removed consumer init ios task because no longer required.
7+
* Consumer add uses $root variable in local paths in .klutter-plugins file.
8+
* Add logic to klutter_plugin_loaders.gradle.kts to replace $root variable with local path (backwards compatible).
59

610
## 0.2.4
711
* Documentation update to point-out the Android Studio and Intellij IDE plugins.

README.md

Lines changed: 11 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ The Klutter dependency is a requirement for both using and creating plugins with
4242
Add the Klutter library to dependencies in the pubspec.yaml:
4343

4444
```yaml
45-
dependencies:
45+
dev_dependencies:
4646
klutter: ^0.3.0
4747
```
4848
@@ -149,16 +149,15 @@ The following steps describe how to create a Flutter plugin project and initiali
149149
1. Create Flutter plugin project.
150150
2. [Installation](#Installation).
151151
3. Initialization.
152-
4. Build Platform module.
153-
5. Generate Dart code.
154-
6. Verify your plugin.
152+
4. Build Platform module and generate Dart code.
153+
5. Verify your plugin.
155154

156155
Run the following to create a new Flutter plugin,
157156
substituting 'org.example' with your organisation name
158157
and 'plugin_name' with your plugin name:
159158

160159
```shell
161-
flutter create --org com.example --template=plugin --platforms=android,ios plugin_name
160+
flutter create --org com.example --template=plugin --platforms=android,ios -a kotlin -i swift plugin_name
162161
```
163162

164163
Install the Klutter Framework as dependency and then run:
@@ -170,13 +169,7 @@ flutter pub run klutter:producer init
170169
Build the platform module by running the following in the root folder (takes a few minutes!):
171170

172171
```shell
173-
flutter pub run klutter:producer install=platform
174-
```
175-
176-
Generate the plugin Dart code:
177-
178-
```shell
179-
flutter pub run klutter:producer install=library
172+
./gradlew clean build -p "platform"
180173
```
181174

182175
Now test the plugin by following the steps outlined [here](#Usage) in the root/example project.
@@ -186,28 +179,26 @@ When done you can run the example project from the root/example/lib folder and s
186179
1. [App won't start on...](#App%20won't%20start)
187180

188181
## App won't start
189-
190182
Make sure you have followed all the following steps:
191-
- flutter create <your_plugin_name> --org <your_organisation> --template=plugin --platforms=android,ios.
183+
- flutter create <your_plugin_name> --org <your_organisation> --template=plugin --platforms=android,ios -a kotlin -i swift.
192184
- [klutter](https://pub.dev/packages/klutter) is added to the dependencies in your pubspec.yaml
193185
(both the plugin and plugin/example for testing).
194186
- do flutter pub get in both root and root/example folder.
195187
- do flutter pub run klutter:producer init in the root folder.
196-
- do flutter pub run klutter:producer install=library in the root folder.
197-
- do flutter pub run klutter:producer install=platform in the root folder.
188+
- do ./gradlew clean build -p "platform" in the root folder.
198189
- do flutter pub run klutter:consumer init in the root/example folder.
199190
- do flutter pub run klutter:consumer add=<your_plugin_name> in the root/example folder.
200191

201192
### For Android emulator:
202193
There should be a .klutter-plugins file in the root/example folder containing an entry for your plugin.
203194
If not then do flutter pub run klutter:consumer add=<your_plugin_name> in the root/example folder again.
204195

205-
There should be a platform.aar file in the root/android/klutter folder. If not then do flutter pub run
206-
klutter:producer install=platform from the root folder.
196+
There should be a platform.aar file in the root/android/klutter folder.
197+
If not then do ./gradlew clean build -p "platform" from the root folder.
207198

208199
### For iOS simulator:
209-
There should be a Platform.xcframework folder in root/ios/Klutter. If not then do flutter pub run
210-
klutter:producer install=platform from the root folder.
200+
There should be a Platform.xcframework folder in root/ios/Klutter.
201+
If not then do ./gradlew clean build -p "platform" from the root folder.
211202

212203
If there's an error message saying unable to find plugin or similar then run pod update
213204
(or for Mac M1 users you might have to do: arch -x86_64 pod install) in the root/example/ios

lib/res/FlutterEngine.xcframework/Info.plist

Lines changed: 0 additions & 44 deletions
This file was deleted.
Binary file not shown.

0 commit comments

Comments
 (0)