Skip to content

Commit

Permalink
Merge pull request #4 from rod-moraes/master
Browse files Browse the repository at this point in the history
Ajustes para o build da aplicação e assinatura do app
  • Loading branch information
guilhermedjr authored Nov 7, 2023
2 parents 76b5c80 + 1962206 commit 486690d
Show file tree
Hide file tree
Showing 6 changed files with 41 additions and 12 deletions.
1 change: 1 addition & 0 deletions src/MobileApp/android/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ GeneratedPluginRegistrant.java
# Remember to never publicly share your keystore.
# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app
key.properties
keystore.jks
18 changes: 15 additions & 3 deletions src/MobileApp/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ if (localPropertiesFile.exists()) {
localProperties.load(reader)
}
}
def keystoreProperties = new Properties()
def keystorePropertiesFile = rootProject.file('key.properties')
if (keystorePropertiesFile.exists()) {
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
}

def flutterRoot = localProperties.getProperty('flutter.sdk')
if (flutterRoot == null) {
Expand Down Expand Up @@ -42,15 +47,22 @@ android {
minSdkVersion 21
targetSdkVersion 33
ndkVersion "25.1.8937393"
multiDexEnabled true
versionCode flutterVersionCode.toInteger()
versionName flutterVersionName
}

signingConfigs {
release {
keyAlias keystoreProperties['keyAlias']
keyPassword keystoreProperties['keyPassword']
storeFile keystoreProperties['storeFile'] ? file(keystoreProperties['storeFile']) : null
storePassword keystoreProperties['storePassword']
}
}
buildTypes {
release {
// TODO: Add your own signing config for the release build.
// Signing with the debug keys for now, so `flutter run --release` works.
signingConfig signingConfigs.debug
signingConfig signingConfigs.release
}
}
}
Expand Down
19 changes: 16 additions & 3 deletions src/MobileApp/android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="com.CSoft.ReachUp">
<!-- io.flutter.app.FlutterApplication is an android.app.Application that
calls FlutterMain.startInitialization(this); in its onCreate method.
Expand All @@ -11,16 +12,28 @@
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
<uses-permission android:name="android.permission.RECORD_AUDIO"/>
<application
android:name="com.CSoft.ReachUp"
android:name="io.flutter.app.FlutterApplication"
android:label="ReachUp"
android:icon="@mipmap/ic_launcher">
android:icon="@mipmap/ic_launcher"
android:exported="true"
tools:node="merge">
<receiver android:name="org.altbeacon.beacon.startup.StartupBroadcastReceiver" android:exported="false"
tools:node="merge">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED" />
<action android:name="android.intent.action.ACTION_POWER_CONNECTED" />
<action android:name="android.intent.action.ACTION_POWER_DISCONNECTED" />
</intent-filter>
</receiver>
<activity
android:name=".MainActivity"
android:launchMode="singleTop"
android:theme="@style/LaunchTheme"
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
android:hardwareAccelerated="true"
android:windowSoftInputMode="adjustResize">
android:windowSoftInputMode="adjustResize"
android:exported="true"
tools:node="merge">
<!-- Specifies an Android theme to apply to this Activity as soon as
the Android process has started. This theme is visible to the user
while the Flutter UI initializes. After that, this theme continues
Expand Down
2 changes: 2 additions & 0 deletions src/MobileApp/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ buildscript {
ext.kotlin_version = '1.6.10'
repositories {
google()
mavenCentral()
jcenter()
}
dependencies {
Expand All @@ -13,6 +14,7 @@ buildscript {
allprojects {
repositories {
google()
mavenCentral()
jcenter()
}
}
Expand Down
11 changes: 6 additions & 5 deletions src/MobileApp/lib/View/SignView/SignUp.view.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
// @dart=2.9
import 'dart:convert';

import 'package:ReachUp/Component/Database/Database.db.dart';
import 'package:ReachUp/Component/Dialog/CustomDialog.component.dart';
import 'package:ReachUp/Controller/Account.controller.dart';
import 'package:ReachUp/Controller/Category.controller.dart';
Expand Down Expand Up @@ -314,11 +317,9 @@ class _StepperBodyState extends State<StepperBody> {
EasyLoading.show(status: "Carregando");
accountController.signUp().then((value) {
EasyLoading.dismiss();
Globals.user = value;
Database.insert(
key: "user",
value: jsonEncode(
Globals.user.toJson()));
Globals.user = value;
Database.insert(
key: "user", value: jsonEncode(Globals.user.toJson()));
});

List<Category> categories = new List<Category>();
Expand Down
2 changes: 1 addition & 1 deletion src/MobileApp/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ description: Mobile application for indoor location, provides blind and visually

publish_to: 'none'

version: 1.0.0+1
version: 1.0.6+6

environment:
sdk: "2.12.0"
Expand Down

0 comments on commit 486690d

Please sign in to comment.