I tried to build the project from vs code terminal but it just threw an error
According to the image, there is another folder inside of flutter-quizstar-master-step, therefore execute:
cd flutter-quizstar-master
then
flutter build apk
Related
when I try to use image_picker and run the flutter project it gives me error
A problem occurred configuring project ':image_picker_android'.
Could not load compiled classes for build file 'C:\Users\ZerpSteve\Documents\flutter_windows_2.10.2-stable\flutter.pub-cache\hosted\pub.dartlang.org\image_picker_android-0.8.5\android\build.gradle' from cache.
Use this command in your flutter project folder and rerun your project.
flutter clean && flutter pub get
In VSCode Flutter Emulator doesnt load.
Error: No pubspec.yaml file found.
This command should be run from the root of your Flutter project.
Flutter run doesnt work.
make sure you are in the root of your project.
if not - right click on your main.dart file and run that file on terminal.
then flutter clean & pub get & run worked for me .
When I press run flutter it is show
Error: No pubspec.yaml file found. This command should be run from the root of your Flutter project.
the Error image
flutter doctor
How can I fix it?
The ua is not the correct directory for your project. You need to change your working directory with:
cd ali
Then, you can flutter run.
Error: No pubspec.yaml file found.
This command should be run from the root of your Flutter project.
Do not run this command from the root of your git clone of Flutter.
Please note that I have executed the same project previously more than once.
You are in the wrong folder in the command prompt..navigate to the root directory of your project in which the pubspec.yaml is placed.
C:\flutter\flutter_windows_v1.9.1+hotfix.2-stable\flutter\bin\flutter.bat --no-color build apk
Target file "lib\main.dart" not found.
Process finished with exit code 1
You can set an entry point like this:
flutter run --target=lib/Login.dart
flutter build apk --target=lib/Login.dart
This article shows you how to set up IDE (VSCode/AS) to build another target file.
I don't think you should be changing the entry file, you can always use the main.dart without issues and then set the Entry class there. This doesn't stop your app from working.