Reputation: 21
I used android studio to import flutter project.I fixed some bugs but the run
button is still disabled as in the image below.
enter image description here
when i clicked the Make Project
button , i get this error message
Task 'assemble' not found in root project 'flutter_project_name'.
i know this issue is solved her in android projects but,
How to solve it in flutter project ?
and Does this error is the reason why run
button is disabled?
the exception is not related to the button disable issue.
the run
button problem is solved by creating flutter run configuration
Edit Configuration
plus
icon.flutter
note : the exception does not prevent the project from running.
Upvotes: 0
Views: 3809
Reputation: 161
the problem for me was that i didn't had settings.gradle under root project so, add that file under root project flutter_project_name and add this line in it
include ':app'
hope it works.
Upvotes: 2
Reputation: 10463
Creating a Flutter project should set a run config by default, and importing a Flutter project should be able to read the run config from the project as well. It's likely that the Flutter project that you've imported doesn't have a run config set up.
In this case, you can simply click Add configuration...
from the menu bar.
Click Add New Configuration
, select Flutter
, and set the Flutter project's main.dart on Dart entry point
.
Upvotes: 0