You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Publish Flutter engine in online maven repo #11439
This is not functional and only provides stubbed implementations of the Flutter API.
All methods in all classes throw a runtime exception. Because an Android app runs
on a device, it will never use these libraries for execution, but the API compatibility
allows an app to be compiled as if it was the real library.
Library user imports the ExamplePlugin into his Android project using gradle and binds it to implement Android part of a Flutter plugin: example activity
no need all the android framework settings i.e. project files, resources, gradle build settings and the manifest.
android framework is no needed too and the library is published to be available via gradle and to be reused in different android apps
otherwise each flutter plugin contains a full android project and requires a lot of attention to it's config files.
There are basically two options for including external libraries in your Android application. The first is to manually copy the jars into the libs directory within your project and update the classpath. The disadvantage is that you have to manage the dependencies manually. Alternatively, a third party plugin such as the Maven Android Plugin can be utilized to automatically include the dependencies from a Maven repository.
In order to build an android application on the command line (and therefore in continuous integration environments..) the standard way is to use build systems. One of the most common systems with many additional benefits beyond ant is Apache Maven. Gradle understand this repository format and can retrieve artifacts from it.
Currently users that want to build their Android project with Gradle need to publish the flutter.jar artifact into their private repository server or at minimum into their private local repository.
On top with the current approach you have to manage the build.gradle file for each(!) plugin keeping it's settings aligned with compileSdkVersion, buildToolsVersion, minSdkVersion, targetSdkVersion, multiDexEnabled, dexOptions.javaMaxHeapSize and so on.
@JFixby we have started generating Maven artifacts. We will be updating the docs by the end of this month, so you can set the dependency on the embedding directly from Gradle.
Reacted by Neil Jay Warner, Pooja Bhaumik and Arto Bendiken
When it is something really solid that works on iOS and Android both really well please make a huge deal about it in the conferences and YouTube channel and Twitter feed and all of that... It should be able to get to a point where an ordinary iOS or Android app could use it without caring or even really knowing what it was written in right?
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.
Activity
eseidelGoogle commentedon Jul 28, 2017
This is probably an @mravn-google or @jason-simmons question. :)
sethladd commentedon Jul 28, 2017
cc @mit-mit
Hixie commentedon Aug 1, 2017
Can you elaborate on why you want this?
JFixby commentedon Aug 1, 2017
Usage scenario assuming Flutter API stub is published on a repo:
build.gradlefile:Here is an example of such class: android implementation of a Flutter plugin
The class depends on the
io.flutter.plugin.common.*ExamplePlugininto his Android project usinggradleand binds it to implement Android part of a Flutter plugin: example activityJFixby commentedon Aug 2, 2017
JFixby commentedon Aug 8, 2017
Currently users that want to build their Android project with Gradle need to publish the flutter.jar artifact into their private repository server or at minimum into their private local repository.
On top with the current approach you have to manage the
build.gradlefile for each(!) plugin keeping it's settings aligned withcompileSdkVersion,buildToolsVersion,minSdkVersion,targetSdkVersion,multiDexEnabled,dexOptions.javaMaxHeapSizeand so on.[-]Official Flutter API stub artifact[/-][+]Official Flutter API stub artifact on maven[/+]8 remaining items
[-]Official Flutter API stub artifact on maven[/-][+]Publish Flutter engine in online maven repo[/+]jmagman commentedon Aug 9, 2019
@blasten
JFixby commentedon Aug 10, 2019
neiljaywarner commentedon Aug 10, 2019
Jfixby
Sorry I did not acknowledge you fulfilling my request. I appreciate it.
Perhaps flutter's approach produces some of its success and some of its weaknesses..
blasten commentedon Aug 10, 2019
@JFixby we have started generating Maven artifacts. We will be updating the docs by the end of this month, so you can set the dependency on the embedding directly from Gradle.
neiljaywarner commentedon Aug 10, 2019
When it is something really solid that works on iOS and Android both really well please make a huge deal about it in the conferences and YouTube channel and Twitter feed and all of that... It should be able to get to a point where an ordinary iOS or Android app could use it without caring or even really knowing what it was written in right?
dnfield commentedon Aug 19, 2019
blasten commentedon Oct 1, 2019
This is already implemented. http://download.flutter.io/ is the repository.
github-actions commentedon Aug 27, 2021
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of
flutter doctor -vand a minimal reproduction of the issue.