Closed parkkh12 closed 4 months ago
See the step-by-step guide.
You will need to clone the mobileraker_pro_pub
repo and use the correct folder structure. Afterwards, update the mobileraker_pro
dependency in the pubspec.yaml
to use the folder/repo mobileraker_pro_pub
.
Let me know if you need further assistance to build the app.
@Clon1998 I'm really sorry, but could you please explain in detail how to set it up? No matter how closely I follow the guide, I encounter an error with pro_pub. I'm not a developer and I'm using Flutter for the first time as a hobbyist.
@Clon1998 I'm really sorry, but could you please explain in detail how to set it up? No matter how closely I follow the guide, I encounter an error with pro_pub. I'm not a developer and I'm using Flutter for the first time as a hobbyist.
Sure! I'll do a more detailed write up once I am back home. I hope I can do it today but I might need to move it to Sunday.
Hey, I hope this helps. Its a bit more detailed compared with the instructions from the main README.
mobileraker
RepositoryYou will need to clone the mobileraker
Repository.
Install Git: If you don't have Git installed, download it from Git’s website.
Clone the Repository:
cd path/to/your/projects
mobileraker
repository:
git clone https://github.com/Clon1998/mobileraker.git
mobileraker_pro_pub
RepositoryYou need to clone another project that the mobileraker project depends on.
Install Git: If you don't have Git installed, download it from Git’s website.
Clone the Repository:
cd path/to/your/projects
mobileraker_pro_pub
repository:
git clone https://github.com/Clon1998/mobileraker_pro_pub.git
Make sure your folders are organized like this:
.
├── mobileraker
└── mobileraker_pro_pub
pubspec.yaml
Now you need to tell Flutter where to find the mobileraker_pro_pub
project.
pubspec.yaml
file located in the mobileraker
project folder.dependencies:
and make sure it looks like this:dependencies:
...
mobileraker_pro:
path: ../mobileraker_pro_pub
This tells Flutter that the mobileraker_pro
dependency is located in the mobileraker_pro_pub
folder that is one level up from the mobileraker
folder.
You need to generate some files that are necessary for the app to work correctly.
Open the terminal or command prompt.
Navigate to the root folder of the mobileraker
project:
cd path/to/your/projects/mobileraker
flutter pub get
flutter packages pub run build_runner build
flutter pub get
fetches the dependencies listed in pubspec.yaml
.flutter packages pub run build_runner build
generates files needed for the app.common
folder:cd common
flutter pub get
flutter packages pub run build_runner build
Navigate to the mobileraker_pro_pub
folder:
cd path/to/your/projects/mobileraker_pro_pub
Run the following commands:
flutter pub get
flutter packages pub run build_runner build
Firebase provides backend services for your app, such as authentication and database.
flutterfire configure
firebase_options.dart
After configuring Firebase, you'll have a file named firebase_options.dart
.
firebase_options.dart
File: This file is located in the mobileraker_pro_pub
folder. Open it with your IDE.firebase_options.dart
file that was generated by the flutterfire configure
command.firebase_options.dart
file in mobileraker_pro_pub
with the new contents.You are now ready to run the app!
Hey, I hope this helps. Its a bit more detailed compared with the instructions from the main README.
1. Clone the
mobileraker
RepositoryYou will need to clone the
mobileraker
Repository.How to Clone:
- Install Git: If you don't have Git installed, download it from Git’s website.
Clone the Repository:
- Open your terminal or command prompt.
- Navigate to the location where you want to store the projects. For example:
cd path/to/your/projects
- Run the following command to clone the
mobileraker
repository:git clone https://github.com/Clon1998/mobileraker.git
2. Clone the
mobileraker_pro_pub
RepositoryYou need to clone another project that the mobileraker project depends on.
How to Clone:
- Install Git: If you don't have Git installed, download it from Git’s website.
Clone the Repository:
- Open your terminal or command prompt.
- Navigate to the location where you want to store the projects. For example:
cd path/to/your/projects
- Run the following command to clone the
mobileraker_pro_pub
repository:git clone https://github.com/Clon1998/mobileraker_pro_pub.git
3. Check Folder Structure:
Make sure your folders are organized like this:
. ├── mobileraker └── mobileraker_pro_pub
4. Configure Dependency in
pubspec.yaml
Now you need to tell Flutter where to find the
mobileraker_pro_pub
project.Steps to Configure:
- Open the
pubspec.yaml
file located in themobileraker
project folder.- Find the section that starts with
dependencies:
and make sure it looks like this:dependencies: ... mobileraker_pro: path: ../mobileraker_pro_pub
This tells Flutter that the
mobileraker_pro
dependency is located in themobileraker_pro_pub
folder that is one level up from themobileraker
folder.5. Generate Required Files
You need to generate some files that are necessary for the app to work correctly.
How to Generate Files:
- Open the terminal or command prompt.
- Navigate to the root folder of the
mobileraker
project:cd path/to/your/projects/mobileraker
- Run the following commands one by one:
flutter pub get flutter packages pub run build_runner build
flutter pub get
fetches the dependencies listed inpubspec.yaml
.flutter packages pub run build_runner build
generates files needed for the app.
- Navigate to the
common
folder:cd common
- Run the following commands:
flutter pub get flutter packages pub run build_runner build
- Navigate to the
mobileraker_pro_pub
folder:cd path/to/your/projects/mobileraker_pro_pub
- Run the following commands:
flutter pub get flutter packages pub run build_runner build
6. Configure Firebase
Firebase provides backend services for your app, such as authentication and database.
Steps to Configure Firebase:
- Open Your Terminal or Command Prompt.
- Run the Command:
flutterfire configure
- Follow the instructions in the terminal to configure Firebase for both Android and iOS platforms.
7. Update
firebase_options.dart
After configuring Firebase, you'll have a file named
firebase_options.dart
.How to Update:
- Find the
firebase_options.dart
File: This file is located in themobileraker_pro_pub
folder. Open it with your IDE.- Copy the Content: Copy the contents of the
firebase_options.dart
file that was generated by theflutterfire configure
command.- Replace the Existing File: Replace the contents of the
firebase_options.dart
file inmobileraker_pro_pub
with the new contents.- Save the file.
8. Run the App
You are now ready to run the app!
How to Run the App:
- Open Your IDE.
Make Sure Your Device or Emulator is Running.
- You can use a physical device or an emulator.
- If you don't have an emulator set up, you can create one from the Android Studio or Visual Studio Code.
Run the App:
- In Visual Studio Code, click the green play button at the top right.
- In Android Studio, click the green play button in the toolbar
I kept trying, but the same error kept occurring.
I managed to resolve it as follows:
It seems that the dependencies for mobileraker need to be installed last, after common and pro_pub.
The build was successful!
That is a good point. I'll update the readme and adjust the order of execution. Please note that some UI elements use placeholders as they are actually implemented ok my own private repo.
Feature Request
Problem Description
I updated Mobileraker_pro to the latest version, completely removed the project, and then recreated it following the procedures. However, during the build process, while the import is recognized normally, the functions inside Mobileraker_pro are not recognized.
Proposed Solution
What does the following comment in pubspec.yaml mean: "#path: ../mobileraker_pro_public # Uncomment this line if you want to contribute to the project. Also remove the line above"? Is this comment related to the issue?
Alternatives Considered
If you've thought of any alternative solutions or features, please briefly describe them here.
Additional Context
I want to contribute by translating to Korean and am working on the Korean translation. I need to build and use the app myself to check for any errors in the translation, but the app does not build at all. What should I do? Below are my configuration screenshots.
Add any screenshots, examples, or additional context to help us understand your feature request better.
Checklist To help us understand your feature request, please ensure you've covered the following points:
Your input is valuable in shaping the development of our project. Thank you for taking the time to submit your feature request!