Add environment variables
This commit is contained in:
parent
a082441826
commit
c9769fcada
2
Mobile/.gitignore
vendored
2
Mobile/.gitignore
vendored
@ -41,3 +41,5 @@ app.*.map.json
|
||||
/android/app/debug
|
||||
/android/app/profile
|
||||
/android/app/release
|
||||
|
||||
environment.json
|
||||
|
7
Mobile/.run/main.dart.run.xml
Normal file
7
Mobile/.run/main.dart.run.xml
Normal file
@ -0,0 +1,7 @@
|
||||
<component name="ProjectRunConfigurationManager">
|
||||
<configuration default="false" name="main.dart" type="FlutterRunConfigurationType" factoryName="Flutter">
|
||||
<option name="additionalArgs" value="--dart-define-from-file environment.json" />
|
||||
<option name="filePath" value="$PROJECT_DIR$/lib/main.dart" />
|
||||
<method v="2" />
|
||||
</configuration>
|
||||
</component>
|
15
Mobile/.vscode/launch.json
vendored
Normal file
15
Mobile/.vscode/launch.json
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
{
|
||||
"version": "0.2.0",
|
||||
"configurations": [
|
||||
{
|
||||
"name": "Launch",
|
||||
"request": "launch",
|
||||
"type": "dart",
|
||||
"program": "lib/main.dart",
|
||||
"args": [
|
||||
"--dart-define-from-file",
|
||||
"environment.json"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
6
Mobile/README.md
Normal file
6
Mobile/README.md
Normal file
@ -0,0 +1,6 @@
|
||||
# SkanTravels frontend
|
||||
|
||||
### Running
|
||||
|
||||
- Copy `environment.example.json` to `environment.json` and fill out the values
|
||||
- Run `flutter run --dart-define-from-file environment.json`
|
4
Mobile/environment.example.json
Normal file
4
Mobile/environment.example.json
Normal file
@ -0,0 +1,4 @@
|
||||
{
|
||||
"AUTH_SERVICE_HOST": "http://localhost:5287",
|
||||
"APP_SERVICE_HOST": "http://localhost:8080"
|
||||
}
|
@ -1,16 +0,0 @@
|
||||
# mobile
|
||||
|
||||
A new Flutter project.
|
||||
|
||||
## Getting Started
|
||||
|
||||
This project is a starting point for a Flutter application.
|
||||
|
||||
A few resources to get you started if this is your first Flutter project:
|
||||
|
||||
- [Lab: Write your first Flutter app](https://docs.flutter.dev/get-started/codelab)
|
||||
- [Cookbook: Useful Flutter samples](https://docs.flutter.dev/cookbook)
|
||||
|
||||
For help getting started with Flutter development, view the
|
||||
[online documentation](https://docs.flutter.dev/), which offers tutorials,
|
||||
samples, guidance on mobile development, and a full API reference.
|
Loading…
Reference in New Issue
Block a user