eliud_core 1.0.16+7 eliud_core: ^1.0.16+7 copied to clipboard
Eliud core
eliud #
- Introduction
- Chapter I. Create a simple "hello world" Android app
- Step 1: Decide on domain name and app nickname
- Step 2: Create a new google account
- Step 3: Create a new firebase project
- Step 4: Configure your project
- Step 5: Setup Firebase database
- Step 6: Setup Firebase storage
- Step 7: Setup Google Authentication
- Step 8: Generate a Private Key
- Step 9: Add Firebase Android App
- Step 10: Create Android Studio project
- Step 11: Copy google_services.json
- Step 12: Apply firebase SDK instructions
- Step 13: Add key store file to your project
- Step 14: Update pubspec.yaml
- Step 15: Update main.dart
- Step 16: Clean up
- Step 17: minSdkVersion
- Step 18: AD_ID
- Step 19: Run your app
- Step 20: Add some basic functionality to your app
- Chapter II. Create the webapp and configure firebase
- Step 1: Buy domain
- Step 3: Logo
- Step 4: Add Firebase Web App
- Step 5: Retrieve hosting details
- Step 6: Setup email forwarding
- Step 7: Subscribe to mailtrap
- Step 8: Setup DNS records for firebase hosting
- Step 9: Setup DNS records for mailtrap
- Step 10: Verify mailtrap setup
- Step 11: Update firebase
- Step 12: Enable APIs
- Step 13: Configure oauth web client
- Step 14: Configure Android Studio project for web
- Step 15: Cors`
- Step 16: Deploy your website
- Step 17: Create policies / policy pages
- Step 18: Create membership dashboard page
- Step 19: Setup oauth consent
- Step 20: Start your free google GCP trial 300 USD
- Chapter III. Create the ios app
- Step 1: Register as apple developer
- Step 2: Create or Update an Apple App ID
- Step 3: Register your apple device
- Step 4: Create an Apple Service ID
- Step 5: Register a Private Key for you apple developer account
- Step 6: Enable Apple sign-in on Firestore
- Step 7: Provide Web Authentication Configuration for your Service ID
- Step 8: Create Apple firebase app
- Step 9: Setup ios project
- Step 10: Configure the Android Studio project for apple
- Step 11. GoogleService-Info.plist
- Step 12. Add a URL scheme to your project
- Troubleshouting steps
- Chapter IV. Deploy to android store
- Chapter V. Deploy to apple store
- Step 1: Enroll for the Apple Developer Program.
- Step 2: Create an app on App Store Connect
- Step 3: Create simulators
- Step 4: Create screenshots
- Step 5: Provide app detailks
- Step 6: Provide App Privacy details
- Step 7: Create a build archive
- Step 8: Upload to App Store Connect
- Step 10: Release your app to the App Store
- Chapter VI. Extend the app with other packages
- Chapter VII. Write and integrate your own code / packages
- Appendix A. Overview packages
Introduction #
Documentation for eliud is under construction. Please be patient.
- Eliud technology is open source technology.
- The technology allows to build apps and/or websites. Today, app content can include photo galleries, pages with videos and images (html), social media, chat with or between members, your shop / shopping cart, photo sliders, documents, and more. A complete list below.
- Eliud is a layer on top of Flutter. Flutter is an open-source UI software development kit created by Google. Flutter allows to develop cross platform applications for iOS, Android and web. Flutter supports Linux, macOS, Windows and Google Fuchsia. This hasn't been tested with eliud packages yet.
- For those who know Worpress: Eliud is to Flutter as Wordpress is to html:
- Html allows you to construct webpages. However, html requires some level of technical knowledge about building webpages.
- Wordpress and many other similar technologies allow people without knowledge of html to build webpages and websites.
- Flutter allows to build websites and apps, or even Windows, Linux, macOS and Google Fuchsia apps. However, Flutter requires programming skills and technical knowledge.
- Eliud allows people without programming skills and technical knowledge to build cross platform apps and websites.
- Html allows you to construct webpages. However, html requires some level of technical knowledge about building webpages.
- Eliud is pluggable technology, allowing developers
- to extend / add functionalities by means of plugins / packages.
- to change look and feel through using styles.
- A website / app built with Eliud consist of its core Eliud package + one or more Eliud plugins. The app is constructed by configuring it. Configuration, images and videos are stored in Firebase database and Firebase storage.
The below steps document the creation of your own android + apple + web app and includes all instructions, all the way to pushing your app into the apple app store, android store and web.
Example Eliud apps #
These are some example apps which demonstrate what eliud can give you. Everything used is open source, part of eliud project.
App | Ios | Android | Web | |
---|---|---|---|---|
Juuwle - An online store for jewels | Juuwle on the App Store | Juuwle on Google Play | https://juuwle.net | |
Minkey - Community making apps online | This type of app is not allowed on apple store | Minkey on Google Play | https://minkey.io | |
Thoma5 - Profile of Thomas. Under construction | In development | In development | https://thoma5.com |
Chapter I. Create a simple "hello world" Android app #
This guide are all steps to create a minimum android, iOS or web app with Eliud.
Whenever this pops up, make note of this for what this is in your case, as you'll need it at some later stage. In the below text we provided this information whilst creating thoma5, as an example. Obviously for sensitive information, like passwords, we've provided fake info. |
Step 1: Decide on domain name and app nickname #
Decide your app name and web domain.
|
Step 2: Create a new google account #
- Goto https://www.google.com/account/about/
- Select "Create an account"
- Follow on screen instructions (recommended to use default settings)
|
Step 3: Create a new firebase project #
- Goto https://console.firebase.google.com
- Select "Create a project"
- And follow on screen instructions (recommended to use default settings)
|
Step 4: Configure your project #
- Goto https://console.firebase.google.com
- Select your project
- Select Project Overview > Project settings
- Select support email. Use your google account
Step 5: Setup Firebase database #
-
Select your project
-
Select Build > Firebase database
-
Select "Create database"
-
And follow on screen instructions (recommended to use default settings, start in production mode)
-
With Cloud Firestore open, click on Rules and copy/paste the contents of firestore.rules and publish.
For convenience, and to familiarise yourself with firebase, at this point we copy/paste these rules. However, later we will upload the same rules more efficiently using firestore commands from command line
Step 6: Setup Firebase storage #
-
Select your project
-
Select Build > Storage
-
Select "Get started"
-
And follow on screen instructions (recommended to use default settings, start in production mode)
-
With Storage open, click on Rules and copy/paste the contents of storage.rules and publish.
For convenience, and to familiarise yourself with firebase, at this point we copy/paste these rules. However, later we will upload the same rules more efficiently using firestore commands from command line
-
With storage page open, retrieve your "bucket" from the url. You bucket is the bit in front of ".appspot" in the url. In our case the url is https://console.firebase.google.com/project/thoma5/storage/thoma5.appspot.com/files, hence the bucket is thoma5
|
Step 7: Setup Google Authentication #
- Goto https://console.firebase.google.com
- Select your project
- Select Authentication
- Select Sign-in method
- Select Google from Sign-in providers
- Enable the Google sign-in
Step 8: Generate a Private Key #
- Run the following command at command prompt:
keytool -genkey -v -keystore your_keystore_filename -storepass your_keystore_storepass -alias your_keystore_alias -keypass your_keystore_keypass -keyalg RSA -keysize 2048 -validity 36524
-
Then follow onscreen instructions. Then store the key-file in a safe place. You will have to use it multiple times in the future.
-
Now run:
keytool -list -v -alias your_keystore_alias -keystore your_keystore_filename -storepass your_keystore_storepass -keypass your_keystore_keypass
For example:
keytool -genkey -v -keystore %USERPROFILE%\\.android\\thoma5.keystore -storepass abc -alias thoma5key -keypass cde -keyalg RSA -keysize 2048 -validity 36524
keytool -list -v -alias thoma5key -keystore %USERPROFILE%\\.android\\thoma5b.keystore -storepass abc -keypass cde
|
MORE INFO
Step 9: Add Firebase Android App #
- Goto https://console.firebase.google.com
- Select your project
- Click 'Add app' and select platform 'Android'"
- Specify your android package name. This must be the inverse of your domain
- Specify your android app nickname. This is your app nickname
- Paste the SHA-1 key Your keystore SHA1
- Press "Register app"
- Then download the file google-services.json
|
Step 10: Create Android Studio project #
-
Start Android studio
-
Select File > New > New Flutter Project
-
Specify
- Flutter SDK path and press Next
-
Specify
- Project name: e.g. thoma5_app
- Project location: e.g. C:\src\apps\thoma5_app
- Description: e.g. Thoma5 app
- Project type: Should be "Application"
- Organization: e.g. com.thoma5
- Android language: Should be Java
- iOS language: Should be Swift
- Platforms: Should be Android, iOS and Web
❗ IMPORTANT ❗
The android package name specified as Your Android app package name - e.g. com.thoma5.thoma5_app - should be equal to the concatenation of organisation - e.g. com.thoma5 - a dot and the project_name - e.g. thoma5_app
-
Press finish
|
Step 11: Copy google_services.json #
- Switch to the Project view in Android Studio to see your project root directory.
- Move your downloaded google-services.json file into your module (app-level) root directory, e.g. thoma5_app/android/app
Step 12: Apply firebase SDK instructions #
- Goto https://console.firebase.google.com
- Select your project
- Find your app from "your apps" section, then press "See SDK instructions"
- You get to chance to re-download the google_services.json file, skip this by pressing next.
- Now apply the suggestions provided. Make sure to select Groovy (build.gradle) and Java.
At the time of writing this document, the changes to make were:
file | location | add |
---|---|---|
(1) thoma5_app/android/build.gradle | buildscripts > dependencies | classpath 'com.google.gms:google-services:4.3.15' |
(2) thoma5_app/android/app/build.gradle | plugins | id 'com.google.gms.google-services' |
(3) Finally the below at the bottom of thoma5_app/android/app/build.gradle had to be added
dependencies {
// Import the Firebase BoM
implementation platform('com.google.firebase:firebase-bom:32.2.2')
implementation 'com.google.firebase:firebase-analytics'
// Add the dependencies for any other desired Firebase products
// https://firebase.google.com/docs/android/setup#available-libraries
}
Step 13: Add key store file to your project #
-
Create key.properties file in your android directory, e.g thoma5/android/key.properties
-
Populate it with the below keys and values as below. Find your values specified before (follow the links)
- storeFile=Your keystore filename
- storePassword=Your keystore storepass
- keyPassword=Your keystore keypass
- keyAlias=Your keystore alias
e.g.
storePassword=abc keyPassword=cde keyAlias=thoma5key storeFile=c:/Users/thomas/.android/thoma5.keystore
-
Add the following lines to your android apps build.gradle file, e.g. thoma5/android/app/build.gradle
- Load the properties
plugins { ... } // add this after plugins def keystoreProperties = new Properties() def keystorePropertiesFile = rootProject.file('key.properties') if (keystorePropertiesFile.exists()) { keystoreProperties.load(new FileInputStream(keystorePropertiesFile)) } // the rest of the file ...
- Use the keystore for signinConfigs
android { defaultConfig { ... } // add this after defaultConfig and before buildTypes signingConfigs { release { keyAlias keystoreProperties['keyAlias'] keyPassword keystoreProperties['keyPassword'] storeFile keystoreProperties['storeFile'] ? file(keystoreProperties['storeFile']) : null storePassword keystoreProperties['storePassword'] } } buildTypes { ... } }
- Make sure your buildTypes is pointing to the releasing signingConfigs for both debug and release builds
buildTypes { release { signingConfig signingConfigs.release } debug { signingConfig signingConfigs.release debuggable true } }
Step 14: Update pubspec.yaml #
- Update you pubspec.yaml file to reflect the below
---
name: thoma5_app
description: Thoma5
homepage: https://thoma5.com
repository: https://github.com/eliudio/thoma5_app
version: 1.0.0
environment:
sdk: '>=3.1.0 <4.0.0'
flutter: '>=3.0.0'
dependencies:
flutter:
sdk: flutter
eliud_core: ^1.0.6+1
eliud_pkg_create: ^1.0.7+1
eliud_stl_mona: ^1.0.1+6
dev_dependencies:
flutter_lints: ^2.0.0
flutter:
uses-material-design: true
- run pub get
Step 15: Update main.dart #
- Replace your main.dart with these contents.
import 'package:eliud_core/eliud.dart';
import 'package:eliud_core/style/_default/default_style_family.dart';
import 'package:eliud_core/core_package.dart';
import 'package:eliud_pkg_create/creator_package.dart';
import 'package:eliud_pkg_create/tools/basic_app.dart';
import 'package:eliud_pkg_text/text_package.dart';
import 'package:eliud_stl_mona/mona_stl_package.dart';
import 'package:eliud_pkg_create/creator_decoration.dart';
import 'package:eliud_stl_mona/mona_style_family.dart';
import 'package:flutter/cupertino.dart';
import 'package:firebase_core/firebase_core.dart';
Future<void> main() async {
String APP_ID = "THOMA5_APP";
WidgetsFlutterBinding.ensureInitialized();
await Firebase.initializeApp();
var eliud = Eliud();
try {
eliud.registerPackage(CorePackage.instance());
eliud.registerPackage(TextPackage.instance());
eliud.registerPackage(MonaStlPackage.instance());
eliud.registerPackage(CreatorPackage.instance());
// register decorations, these are only required if you want to be able to change your app through the interface
eliud.registerDecoration(CreatorDecoration());
// register style families
eliud.registerStyleFamily(MonaStyleFamily.instance());
eliud.registerStyleFamily(DefaultStyleFamily.instance());
// finish init
eliud.finalizeInitialisation();
} catch (exception) {
throw Exception("Exception whilst initialising the app");
}
// create the app if it doesn't exist
await BasicApp.checkApp(APP_ID);
// let's go !
eliud.run(APP_ID, false);
}
|
Step 16: Clean up #
- Delete the directory test, which contains widget_test.dart
Step 17: minSdkVersion #
-
Goto your Flutter SDK path, subdirectory packages\flutter_tools\gradle\src\main\groovy and edit the file flutter.groovy and open it
-
Update the value for minSdkVersion to be 21
class FlutterExtension { ... /** Sets the minSdkVersion used by default in Flutter app projects. */ static int minSdkVersion = 21 ... }
❗ REMARK ❗
We only need to make this change to the minSdkVersion for the SDK 1 time, i.e. do not repeat this step for future projects / apps.
Step 18: AD_ID #
To be able to upload our app to the google play store, we must specify that our app doesn't have adds. Obviously if you choose to change this then this is possible, but not scope of this guide. To keep things simple...
- Open your AndroidManifest.xml file from your android directory//app/src/main/AndroidManifest.xml, e.g. C:/src/apps/thoma5_app/android/app/src/main/AndroidManifest.xml
- Add xmlns:tools="http://schemas.android.com/tools" at the top, in the manifest node
- Add the following to the bottom of the document
<uses-permission android:name="com.google.android.gms.permission.AD_ID" tools:node="remove"/>
- That results in our case in the following contents:
<manifest xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools">
<application
android:label="thoma5_app"
android:name="${applicationName}"
android:icon="@mipmap/ic_launcher">
<activity
android:name=".MainActivity"
android:exported="true"
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">
<!-- 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
to determine the Window background behind the Flutter UI. -->
<meta-data
android:name="io.flutter.embedding.android.NormalTheme"
android:resource="@style/NormalTheme"
/>
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>
<!-- Don't delete the meta-data below.
This is used by the Flutter tool to generate GeneratedPluginRegistrant.java -->
<meta-data
android:name="flutterEmbedding"
android:value="2" />
</application>
<uses-permission android:name="com.google.android.gms.permission.AD_ID" tools:node="remove"/>
</manifest>
Step 19: Run your app #
- Run the app. Because this is the first time your start the app, it will install a basic app.
- When the app asks to choose an account to login, select your google account
- Ones the basic app is created, it will open
Step 20: Add some basic functionality to your app #
- After you've started your app in the previous step, a "Hello world" screen should appear.
- Press the pen icon to toggle editing mode on.
- Then press the - app button and in the general section
- change the title of your application
- change the home url to your domain url. This is constructed with https:// followed by your domain name
|
- When in edit mode, press the wizard icon to open the wizard dialog box.
- We have only activated a few packages in the code (using eliud.registerPackage), so hence not many wizards are initially available.
- Select signinbutton and press Go!
- Then select signoutbutton and press Go!
Chapter II. Create the webapp and configure firebase #
In the previous steps we've done the foundation to build an app. The next big step is to introduce
- web deployment
- authentication
- functions to support packages
Step 1: Buy domain #
- Buy your domain name, e.g. on squarespace.com.
Step 3: Logo #
- create a logoand store into a file in your project directory, e.g. assets/logo/thoma5-logo-1.png
|
- add the below to pubspec.yaml
dev_dependencies:
flutter_launcher_icons: ^0.13.1
flutter_launcher_icons:
android: true
ios: true
image_path: assets/logo/thoma5-logo-1.png
image_path_ios: assets/logo/thoma5-logo-1.png
remove_alpha_ios: true
web:
generate: true
image_path: assets/logo/thoma5-logo-1.png
- Run the below from your app directory
flutter pub run flutter_launcher_icons:main
Step 4: Add Firebase Web App #
- Goto https://console.firebase.google.com
- Select your project
- Click 'Add app' and select platform 'Web'"
- Provide your app nickname your app nickname
- Select Firebase Hosting.
- Select your project from the drop down box.
- Click on Register app.
- From the "Add Firebase to your web app" page, copy the firebaseConfig details
firebaseConfig |
const firebaseConfig = {
apiKey: "ABcdEfG_H1Ij2KLmNo3PQ_RstUvwXY4Zabcdefg",
authDomain: "thoma5.firebaseapp.com",
projectId: "thoma5",
storageBucket: "thoma5.appspot.com",
messagingSenderId: "263405528229",
appId: "1:123456789012:web:1a2345b6c7890d12ef345h",
measurementId: "G-WL1A23456C"
};
Step 5: Retrieve hosting details #
- Goto https://console.firebase.google.com
- Find the "Add custom domain" button and add
- thoma5.com
- www.thoma5.com, and configure to redirect to thoma5.com
- Make note of the DNS records. We'll need this in a later step.
DNS records | |||||||||||||||||||
Domain: thoma5.com
Domain: www.thoma5.com
|
Step 6: Setup email forwarding #
-
Setup email forwarding
- from info@thoma5.com
- to: your google account
|
Step 7: Subscribe to mailtrap #
- https://mailtrap.io/
- Select sign up
- Select "Use google account" and select your google account
- Select "Email Sending", enter your domain and press "Add Your DomaiN"
- Make note of the DNS records. We'll need this in a later step.
DNS records | ||||||||||||||||||||||||||||||||||||
|
- Click next and in the SMTP/API Settings click API
- Press the "Copy" next to Api Token and keep it somewhere safe. We'll need it soon.
|
Step 8: Setup DNS records for firebase hosting #
Follow the guidelines of your domain registrar to configure your DNS in line with the DNS records specified in the firebase hosting dashboard.
Example 1: domains.google.com #
- Login into your account on https://domains.google.com
- Select "DNS"
- Select "Manage custom records"
- Create new records with the below information, obviously adjusted in line with your DNS records
Host name | Type | TTL | Data |
_acme-challenge | TXT | N/A | aBcdE1FghIj23k4lmnoPqrstUvw5xyZabcdeF6GHiJk |
A | N/A | 123.123.123.123 | |
TXT | N/A | hosting-site=thoma5 | |
www | CNAME | N/A | thoma5.web.app |
Example 2: squarespace.com #
For squarespace, for thoma5.com, this would the be done following these steps:
- Login into your account on https://www.squarespace.com/
- Select your domain from your domains and select "Manage domain settings"
- Edit DNS
- Add the below records, obviously adjusted in line with your DNS records
Host | Type | Priority | Data |
_acme-challenge | TXT | N/A | aBcdE1FghIj23k4lmnoPqrstUvw5xyZabcdeF6GHiJk |
@ | A | N/A | 123.123.123.123 |
@ | TXT | N/A | hosting-site=thoma5 |
www | CNAME | N/A | thoma5.web.app |
MORE INFO
Step 9: Setup DNS records for mailtrap #
Follow the guidelines of your domain registrar to configure your DNS in line with the DNS records specified in the mailtrap dashboard.
Example 1: domains.google.com #
- Login into your account on https://domains.google.com
- Select "DNS"
- Select "Manage custom records"
- Create new records with the below information, obviously adjusted with your DNS records
Host name/td> | Type | TTL | Data |
1abcdef2g34hijkl | CNAME | 3600 | smtp.mailtrap.live |
TXT | 3600 | v=spf1 include:_spf.smtp.mailtrap.live ~all | |
rwmt1._domainkey | CNAME | 3600 | rwmt1.dkim.smtp.mailtrap.live |
rwmt2._domainkey | CNAME | 3600 | rwmt2.dkim.smtp.mailtrap.live |
_dmarc | TXT | 3600 | v=DMARC1; p=none; rua=mailto:dmarc@smtp.mailtrap.live; ruf=mailto:dmarc@smtp.mailtrap.live; rf=afrf; pct=100 |
mt-link | CNAME | 3600 | t.mailtrap.live |
Example 2: squarespace.com #
For squarespace, for thoma5.com, this would the be done following these steps:
- Login into your account on https://www.squarespace.com/
- Select your domain from your domains and select "Manage domain settings"
- Edit DNS
- Add the below records, obviously adjusted in line with your DNS records
Host | Type | Priority | Data |
1abcdef2g34hijkl | CNAME | 3600 | smtp.mailtrap.live |
@ | TXT | 3600 | v=spf1 include:_spf.smtp.mailtrap.live ~all |
rwmt1._domainkey | CNAME | 3600 | rwmt1.dkim.smtp.mailtrap.live |
rwmt2._domainkey | CNAME | 3600 | rwmt2.dkim.smtp.mailtrap.live |
_dmarc | TXT | 3600 | v=DMARC1; p=none; rua=mailto:dmarc@smtp.mailtrap.live; ruf=mailto:dmarc@smtp.mailtrap.live; rf=afrf; pct=100 |
mt-link | CNAME | 3600 | t.mailtrap.live |
MORE INFO
Step 10: Verify mailtrap setup #
- Goto mailtrap.io and sign in with your google account
- From your dashboard, select Email Sending, then Sending Domains
- In the domain verification, select Verify all to verify if you've setup your DNS records correctly
- Follow the steps in Verify Setup, i.e. you'll have to answer some security questions to prove you're building a legit app. In our experience this has been a straightforward process. Questions:
- Describe business / project
- Website
- Linked in profile
- What type of emails do you plan to send?
- How do you get the list of recipients?
- Amount of emails planning to send / month
Step 11: Update firebase #
In this step we wil be updating / uploading:
- storage rules
- firestore indexes and rules
- functions
We have uploaded rules in previous steps during the quick start. That was to get up and running quickly. The proper way to update rules is by using the firebase command line tools, which we will do in this step.
Step 11.1: Install firebase command line tools #
- Open cmd
- Run npm install -g firebase-tools
Step 11.2: Enable APIs #
- Goto https://cloud.google.com/build/docs/deploying-builds/deploy-firebase
- Click "Enable the APIs"
- Follow on screen instructions
Step 11.3: Enable firebase functions #
- Goto https://console.firebase.google.com
- Select your project
- Select functions
- Press "Get started" and select next
Step 11.4 Update firebase #
- Run the below (change firebase project and storage bucket to yours)
mkdir c:\src\apps\thoma5_app_firebase
cd c:\src\apps\thoma5_app_firebase
git clone https://github.com/eliudio/firebase.git
cd c:\src\apps\thoma5_app_firebase\firebase
firebase logout
firebase login
firebase functions:config:set mailtrap.token=a1bc234d5e6f7890123ghij45678k901 mailtrap.sender.email=info@thoma5.com mailtrap.sender.name=Thoma5 app.appname="Thoma5" app.collectionname="order" app.bucket="thoma5" stripe.secret=lalalala --project "thoma5"
firebase deploy --project thoma5
Where...
mailtrap.token | mailtrap token |
mailtrap.sender.email | info@thoma5.com |
mailtrap.sender.name | Thoma5 |
app.collectionname | order |
app.bucket | storage bucket |
project | firebase project |
❗ NOTES ❗
-
You can use quotes to specify parameters. E.g. You could use sendgrid.apikey="NO KEY"
-
In the rules, indexes and functions we cover ALL packages that currently exist. If you only use some packages, then these obsolete rules, indexes and functions could be considered obsolete. However, they're harmless being there and it's the easiest way to get going.
-
When you require your own functions, we recommend to organise multiple functions as described here: https://firebase.google.com/docs/functions/organize-functions?gen=2nd
Step 12: Enable APIs #
- Enable People API: https://console.developers.google.com/apis/api/people.googleapis.com
Step 13: Configure oauth web client #
- Goto https://console.cloud.google.com/apis/credentials
- Find the OAuth 2.0 Client IDs with name "Web client". If you find more than one, select any, e.g. the first.
- Find the "ADD URI" and add these domains:
- Find "web client" and copy the client ID
- Press SAVE
|
Step 14: Configure Android Studio project for web #
Step 14.1: Update pubspec.yaml #
- Add the below dependency to pubspec.yaml
eliud_pkg_wizards: ^1.0.4
This will result in your pubspec.yaml file to look like:
---
name: thoma5_app
description: Thoma5
homepage: https://thoma5.com
repository: https://github.com/eliudio/thoma5_app
version: 1.0.0
environment:
sdk: '>=3.1.0 <4.0.0'
flutter: '>=3.0.0'
dependencies:
flutter:
sdk: flutter
eliud_core: ^1.0.7
eliud_pkg_create: ^1.0.7+1
eliud_pkg_wizards: ^1.0.4
eliud_stl_mona: ^1.0.1+6
dev_dependencies:
flutter_lints: ^2.0.0
flutter_launcher_icons: ^0.13.1
flutter:
uses-material-design: true
flutter_icons:
android: launcher_icon
ios: false
image_path: assets/logo/thoma5-logo-1.png
- Run pub get
Step 14.2: Update main.dart #
- Add the following imports to main.dart
import 'package:flutter/foundation.dart';
import 'package:eliud_pkg_wizards/wizards_package.dart';
import 'package:eliud_pkg_etc/etc_package.dart';
import 'package:eliud_pkg_medium/medium_package.dart';
import 'package:eliud_pkg_workflow/workflow_package.dart';
- Replace the Firebase.initializeApp() line in your main.dart with the below: Make sure the values for apiKey -> measurementId correspond with your values available from firebaseConfig
if (kIsWeb) {
await Firebase.initializeApp(
options: const FirebaseOptions(
apiKey: "ABcdEfG_H1Ij2KLmNo3PQ_RstUvwXY4Zabcdefg",
authDomain: "thoma5.firebaseapp.com",
projectId: "thoma5",
storageBucket: "thoma5.appspot.com",
messagingSenderId: "263405528229",
appId: "1:123456789012:web:1a2345b6c7890d12ef345h",
measurementId: "G-WL1A23456C"
));
} else {
await Firebase.initializeApp();
}
- Add the following extra eliud-dependencies:
eliud.registerPackage(WizardsPackage.instance());
- So basically your main.dart will look like
import 'package:eliud_core/eliud.dart';
import 'package:eliud_core/style/_default/default_style_family.dart';
import 'package:eliud_core/core_package.dart';
import 'package:eliud_pkg_create/creator_package.dart';
import 'package:eliud_pkg_create/tools/basic_app.dart';
import 'package:eliud_pkg_text/text_package.dart';
import 'package:eliud_stl_mona/mona_stl_package.dart';
import 'package:eliud_pkg_create/creator_decoration.dart';
import 'package:eliud_stl_mona/mona_style_family.dart';
import 'package:flutter/cupertino.dart';
import 'package:firebase_core/firebase_core.dart';
import 'package:flutter/foundation.dart';
import 'package:eliud_pkg_wizards/wizards_package.dart';
import 'package:eliud_pkg_etc/etc_package.dart';
import 'package:eliud_pkg_medium/medium_package.dart';
import 'package:eliud_pkg_workflow/workflow_package.dart';
Future<void> main() async {
String APP_ID = "THOMA5_APP";
WidgetsFlutterBinding.ensureInitialized();
if (kIsWeb) {
await Firebase.initializeApp(
options: const FirebaseOptions(
apiKey: "ABcdEfG_H1Ij2KLmNo3PQ_RstUvwXY4Zabcdefg",
authDomain: "thoma5.firebaseapp.com",
projectId: "thoma5",
storageBucket: "thoma5.appspot.com",
messagingSenderId: "263405528229",
appId: "1:123456789012:web:1a2345b6c7890d12ef345h",
measurementId: "G-WL1A23456C"
));
} else {
await Firebase.initializeApp();
}
var eliud = Eliud();
try {
eliud.registerPackage(CorePackage.instance());
eliud.registerPackage(TextPackage.instance());
eliud.registerPackage(MonaStlPackage.instance());
eliud.registerPackage(CreatorPackage.instance());
eliud.registerPackage(WizardsPackage.instance());
// register decorations, these are only required if you want to be able to change your app through the interface
eliud.registerDecoration(CreatorDecoration());
// register style families
eliud.registerStyleFamily(MonaStyleFamily.instance());
eliud.registerStyleFamily(DefaultStyleFamily.instance());
// finish init
eliud.finalizeInitialisation();
} catch (exception) {
throw Exception("Exception whilst initialising the app");
}
// create the app if it doesn't exist
await BasicApp.checkApp(APP_ID);
// let's go !
eliud.run(APP_ID, false);
}
Step 14.3: Create images and stylesheet #
-
Optional: Verify the favicon.png that has been generated before, and optionally create your own (in the web folder). Size is 16 x 16. Use logo as input.
-
Download loading.gif
Download loading.gif and copy into the icons directory of your web folder
- Download styles.css
Download styles.css and copy into the root directory of your web folder
Step 14.4: Update index.html #
- Add the stylesheet
<link rel="stylesheet" type="text/css" href="styles.css">
- Add the Web client ID in metadata
<!== Google sign-in -->
<meta name="google-signin-client_id" content="x-y.apps.googleusercontent.com">
- Add the loading gif
<div id="progress">
</div>
<script>
var img = document.createElement("img");
img.className = "center";
img.src = "icons/loading.gif";
var src = document.getElementById("progress");
src.appendChild(img);
</script>
- Initialise pdfjs
<script src="https://cdn.jsdelivr.net/npm/pdfjs-dist@2.12.313/build/pdf.js" type="text/javascript"></script>
<script type="text/javascript">
pdfjsLib.GlobalWorkerOptions.workerSrc = "https://cdn.jsdelivr.net/npm/pdfjs-dist@2.12.313/build/pdf.worker.min.js";
pdfRenderOptions = {
cMapUrl: 'https://cdn.jsdelivr.net/npm/pdfjs-dist@2.12.313/cmaps/',
cMapPacked: true,
}
</script>
-
Review meta data description and name
-
Which results in the below index.html for thoma5
<!DOCTYPE html>
<html>
<head>
<base href="$FLUTTER_BASE_HREF">
<link rel="stylesheet" type="text/css" href="styles.css">
<meta charset="UTF-8">
<meta content="IE=Edge" http-equiv="X-UA-Compatible">
<meta name="description" content="Thoma5">
<!-- iOS meta tags & icons -->
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<meta name="apple-mobile-web-app-title" content="Thoma5">
<link rel="apple-touch-icon" href="icons/Icon-192.png">
<!== Google sign-in -->
<meta name="google-signin-client_id" content="x-y.apps.googleusercontent.com">
<!-- Favicon -->
<link rel="icon" type="image/png" href="icons/favicon.png"/>
<title>Thoma5</title>
<link rel="manifest" href="manifest.json">
<script>
// The value below is injected by flutter build, do not touch.
const serviceWorkerVersion = null;
</script>
<!-- This script adds the flutter initialization JS code -->
<script src="flutter.js" defer></script>
</head>
<body>
<div id="progress">
</div>
<script>
var img = document.createElement("img");
img.className = "center";
img.src = "icons/loading.gif";
var src = document.getElementById("progress");
src.appendChild(img);
</script>
<script src="https://cdn.jsdelivr.net/npm/pdfjs-dist@2.12.313/build/pdf.js" type="text/javascript"></script>
<script type="text/javascript">
pdfjsLib.GlobalWorkerOptions.workerSrc = "https://cdn.jsdelivr.net/npm/pdfjs-dist@2.12.313/build/pdf.worker.min.js";
pdfRenderOptions = {
cMapUrl: 'https://cdn.jsdelivr.net/npm/pdfjs-dist@2.12.313/cmaps/',
cMapPacked: true,
}
</script>
<div id="loading"></div>
<script>
window.addEventListener('load', function(ev) {
// Download main.dart.js
_flutter.loader.loadEntrypoint({
serviceWorker: {
serviceWorkerVersion: serviceWorkerVersion,
},
onEntrypointLoaded: function(engineInitializer) {
engineInitializer.initializeEngine().then(function(appRunner) {
appRunner.runApp();
});
}
});
});
</script>
</body>
</html>
Step 15: Cors` #
To allow images to be accessed / copied, we need to configure cors access.
- goto your app root dir
- create the following file cors.json, make sure to use your domain url instead of https://thoma5.com
[
{
"origin": ["https://thoma5.com"],
"method": ["GET"],
"maxAgeSeconds": 3600
}
]
- run this command and login with your
gcloud auth login
- run this gsutil command, make sure to replace "thoma5.appspot.com" with your storageBucket which you can find from your firebaseConfig
gsutil cors set cors.json gs://thoma5.appspot.com
MORE INFO
Step 16: Deploy your website #
- Create file firebase.json in your app root directory with these contents
{
"hosting": {
"public": "build/web",
"ignore": [
"firebase.json",
"**/.*",
"**/node_modules/**"
],
"rewrites": [
{
"source": "**",
"destination": "/index.html"
}
]
}
}
- From your app root dir, build and deploy your website
flutter build web --release --no-tree-shake-icons
rem flutter build web --web-renderer html --release --no-tree-shake-icons
call firebase login
call firebase deploy --project thoma5
COMMENT
When you make code changes, e.g. add package dependencies then you will need to repeat 2. to make your changes available on the web. In other words: no other steps - e.g. CORS - need to be repeated.
We use no-tree-shake-icons during our builds. The icons we use in our app are configured / configurable and hence we can not use tree-shake-icons. More details here.
Step 17: Create policies / policy pages #
When publishing apps to the Google Play or Apple App Store, you will need to provide links to privacy policy, terms of service and/or disclaimer. We recommend providing all 3.
For more information, see policies.pdf
To create policies, at this stage, you can choose to use your website or your android app. We're using the web app as we find the interface easier for the below actions. Also, when using the web app we can actually get the URL of the policies easier than with the app.
For each policy, follow these steps:
-
Create a pdf of your policy, then export a jpg for each page and store these files into assets/legal/policy-x-page-b.jpg, ...
-
Open your app. We open thoma5.com
-
Login with your google account
-
Run the policy wizard to create a new policy and accept all default values.
-
Open your left drawer and select "drawer1" button
-
In "Current menu items" find the page you've created in 4 and open details
-
In "General" change the Text and Description, e.g. "Privacy Policy" and confirm the change
-
From the left drawer, open the policy
-
Press the button "page" which you can find at the left center of your page and select "Update page"
-
In general change the Description and Title of the page, e.g. "Privacy Policy"
-
Press the button "policyPresentation" which you can find at the left top of your page
-
Click the AppPolicy and then select the Update button
-
Press the Pages button
-
Delete the existing page and add all the you've saved as jpg files in 1.
-
Construct the url:
- From your web app: open left drawer, select your policy and copy the URL from your browser address bar
- From android app: update the policy page, copy the key from the general section. Now construct the URL:
- Start with https://
- Add your domain name and a slash: thoma5.com/
- Add your APP_ID and a slash: #THOMA5_APP/
- Add the policy page key: 8a75d3fa-d8e9-4ac8-9eb7-851010807502-policy
-
Now repeat for all 3 policies and record the url's
Step 18: Create membership dashboard page #
A membership dashboard page allows members to request the data that your website / app stores of that person and allows to deactivate the account and destroy all data that we keep of this person.
There are many reasons to have a membership dashboard page.
- One is because we want to provide our users the best experience possible. And if they like to leave our site, without leaving a trace, then that's what we offer.
- Second is to be in line with regulations.
- Third is because when uploading the app to android play store, we must provide a link to a page to allow actions
- Run the memberdashboard wizard (from the usual wizard dialog)
- Open the memberdashboard. A dialog (!) for the memberdashboard opens. This means that we don't have a page, but have a dialog.
- Find your dialog ID.
- From your web app: copy the URL from your browser address bar and find the dialog ID after the last occurance of /
- From android app:
- Press the dialog button
- Find the key from General section Here ecd648b7-68a6-4ebb-94b1-d2211c2f7b8f-member_dashboard
- Run the welcome wizard and create a (blank) page. This page should not be accessible from any menu, i.e. deselect AppBar, Home menu and left and right drawer, but select "Available". The page should open after having been created. However, if for some reason you need to find and open it yourself: open "App" from editor mode, select Pages and find the "Welcome" page. Click the menu next to the page and select "Show page".
- Update the page so that it's title is "Membership dashboard" and have empty html contents.
- Copy the key of the page, here 2ffb7c1e-0a84-4f73-bac9-31c57ffb12c4-page
- Now construct the membership URL:
- Start with https://
- Add domain name and a slash: thoma5.com/
- Add your APP_ID and a slash: #THOMA5_APP/
- Add the membership dashboard page retrieved in step 6, i.e. here 2ffb7c1e-0a84-4f73-bac9-31c57ffb12c4-page
- Add a /
- Add the membership dialog ID, retrieved in step 3, i.e. here ecd648b7-68a6-4ebb-94b1-d2211c2f7b8f-member_dashboard
- You should test this URL. Try testing it from a new browser, after having logged out from your site. A dialog will appear to allow to login, after which that membership dashboard will open.
Step 19: Setup oauth consent #
TODO
https://console.cloud.google.com/apis/credentials/consent
select user type "External" select "create" fill in the details requested:
- provide a logo
- privacy policy will be available from https://[your domain name[/#[app name in code]/privacy_policy-1. In our example: https://juuwle.net/#JUUWLE_APP/privacy_policy-1
- We will make the terms of service available from https://[your domain name[/#[app name in code]/terms_of_service-1. In our example: https://juuwle.net/#JUUWLE_APP/terms_of_service-1
- Add your domain as Authorised domains, here juuwle.net
- Specify developers email address
- Add scopes:
- .../auth/userinfo.email
- .../auth/userinfo.profil Then press the "In production" button and go through the on screen instructions
NOTES: Your app will be available to any user with a Google Account.
You've configured your app in a way that requires verification . To complete verification, you will need to provide:
An official link to your app's Privacy Policy, use #privacy_policy_url A YouTube video showing how you plan to use the Google user data you get from scopes A written explanation telling Google why you need access to sensitive and/or restricted user data All your domains verified in Google Search Console
3.6 You will receive an email "OAuth Verification Request for Project" Follow instructions in the email
Step 20: Start your free google GCP trial 300 USD #
TODO: https://cloud.google.com/free
Chapter III. Create the ios app #
- a brief overview of the current base packages
Step 1: Register as apple developer #
- Goto https://developer.apple.com/programs/enroll/
- Follow the on-screen instructions
|
Step 2: Create or Update an Apple App ID #
- https://developer.apple.com/account/resources/identifiers/list
- Press '+' next to "Identifiers"
- Select "App IDs" and press continue
- Select APP and continue
- Description: your app nickname
- Explicit bundle ID: Explicit
- Provide the bundle ID. This is constructed by the invers of your domain name" + your app nickname suffixed with 'ios', here com.thoma5.toma5ios. Do not use '_'
- Enable "Sign in with Apple". No need to press "Edit"
- Press save
- Press register
|
Step 3: Register your apple device #
To be able to develop on your ipad / iphone, you need to register your device. Run these steps:
- https://developer.apple.com/account/resources/devices/list
- Press '+' next to "Devices"
- Select your device name, e.g. iOS, iPadOS, ...
- Provide a device name, e.g. "My dev ipad"
- Specifiy the UDID of your device
MORE INFO
To find the UDID of our devices, this can help...
- To find the UDID on macbook: Click apple icon > About This Mac > More Info.. > System Report > Hardware > Hardware Overview and find the UDID next to "Provisioning UDID".
- For other devices we've found How to Find Your iPhone or iPad's UDID useful.
Step 4: Create an Apple Service ID #
- https://developer.apple.com/account/resources/identifiers/list/serviceId
- Press '+' next to "Identifiers"
- Select "Services IDs" and press continue
- Description: your app nickname, here Thoma5
- Identifier: This is constructed by the invers of your domain name" + your app nickname suffixed with 'service', here com.thoma5.toma5service
- Press save
- Press register
|
Step 5: Register a Private Key for you apple developer account #
- https://developer.apple.com/account/resources/authkeys/list
- Press '+' next to "Keys"
- Provide key name, here Thoma5
- Enable "Sign in with Apple"
- Press "Configure" next to "Sign in with Apple"
- Select your App ID from the list which corresponds to the App Bunble ID and App ID Prefix
- Press "Save"
- Press "Continue"
- Press Register
- Save key ID and download the key
|
- Press "Done"
Step 6: Enable Apple sign-in on Firestore #
- Goto https://console.firebase.google.com
- Select your project
- Select "Authentication"
- Select "Sign-in method"
- Press "Add new provider"
- Select "Apple"
- Enable it with the switch "Enable"
- Services ID, specify value of Service ID, here com.thoma5.thoma5_service
- Apple team ID, find "Team ID" from https://developer.apple.com/account/
- Expand OAuth code flow configuration
- Apple team ID, specify value of Team ID, here 123AB4CDEF
- Key ID, specify value of Key ID, here 12ZYXWVUTS
- Private key, specify contents of Private key
- Finally copy the authorisation callback URL to be used in the next step
|
Step 7: Provide Web Authentication Configuration for your Service ID #
- https://developer.apple.com/account/resources/identifiers/list/serviceId
- Find the service with IDENTIFER = Service identifier
- Enable "Sign in with Apple"
- Click Configure next to "Sign in with Apple"
- Primary App ID: select the app with app that corresponds with the App Bunble ID and App ID Prefix
- Domains and Subdomains: specify domain name, here thoma5.com
- Return URLs: specify the Authorisation callback URL, here https://thoma5.firebaseapp.com/__/auth/handler
- Press "Next"
- Press "Done"
- Press "Continue"
- And finally press "Save"
Step 8: Create Apple firebase app #
- Goto https://console.firebase.google.com
- Select your project
- Press "Add app"
- Select "iOS"
- Apple bundle ID: App Bunble ID
- App nickname: your app nickname, here Thoma5
- App Store ID (optional): leave blank
- Press "Register app"
- Press "Download GoogleService-info.plist"
|
- Press "Next", 3 times
- Press "Continue to the console"
Step 9: Setup ios project #
- Clone your code on your apple machine
- Open the Android Studio project
Step 10: Configure the Android Studio project for apple #
- From Android Studio, right click your project root directory/ios/Runner.xcworkspace and select Flutter > Open iOS module in Xcode
- In Xcode, select Runner folder, then from the list of TARGETS, select Runner
- Then click the "Signing & Capabilities" tab
- From the team field, select your team
- For bundle identifier, specify your App Bunble ID, here com.thoma5.thoma5ios
- Press "+ Capability" then double click "Sign in with Apple"
- Don't forget to select Team
Step 11. GoogleService-Info.plist #
- Copy GoogleService-info.plist from your windows machine to your macbooks, in our case c:\Users\thomas\Downloads\GoogleService-info.plist
- From Xcode, from project Runner, right click folder Runner and select 'Add Files to "Runner"'
- Select the file GoogleService-info.plist you've copied to your macbook
- Makes sure “copy items if needed" is checked
- Press "Add"
- After adding file, find the entry "REVERSED_CLIENT_ID" and copy it's value
|
Step 12. Add a URL scheme to your project #
- Open ios/Runner/Info.plist with a text editor
- Add the below entry, make sure to use your REVERSED_CLIENT_ID
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleTypeRole</key>
<string>Editor</string>
<key>CFBundleURLSchemes</key>
<array>
<string>[com.googleusercontent.apps.YOUR REVERSED_CLIENT_ID]</string>
</array>
</dict>
</array>
MORE INFO
Troubleshouting steps #
- Issue: Failure of running the app due to processor incompatibility issues. Solution: Goto the ios directory and run:
sudo arch -x86_64 gem install ffi
arch -x86_64 pod install
-
Error "The operation couldn’t be completed. Unable to launch com.example.x.y.z-icloud.com because it has an invalid code signature, inadequate entitlements or its profile has not been explicitly trusted by the user.” Solution: On your iPhone/tablet open Settings > General > Device Management > Apple Development: someone@icloud.com then select trust at the top.
-
iOS crash with a stack trace and a message "the default Firebase app has not yet been configured. Add
[FIRApp configure];
(FirebaseApp.configure()
in Swift) to your application" Solution: https://medium.com/vector-com-mm/how-to-fix-ios-crash-during-the-start-firebase-configure-f3477df3154
Chapter IV. Deploy to android store #
Below the minimum required (unless indicated) steps to make your app available on android store. As you will see, the app google provides to upload, maintain, test apps is much broader than what we discuss. We do the bare minimum.
Step 1. Build #
- From your app root directory, run:
flutter clean
flutter build appbundle --release --no-tree-shake-icons -t lib/main.dart
- Record the output file
|
Optional: Step 2. Test the bundle #
- Download bundletool from https://github.com/google/bundletool/releases/ and save in c:\dev\bundletool
- From your app root directory, generate a set of APKs from your app bundle using the bundletool. Make sure to provide the following:
- --bundle: Android bundle
- --output:
- --ks: your keystore filename
- --ks-key-alias: your keystore alias
java -jar c:\dev\bundletool\bundletool-all-1.5.0.jar build-apks ^
--bundle=build/app/outputs/bundle/release/app-release.aab ^
--output=build/app/outputs/bundle/release/thoma5.apks ^
--ks=%USERPROFILE%\\.android\\thoma5.keystore ^
--ks-key-alias=thoma5key
- When asked provide your your keystore storepass
- If you've previously installed your app during development on your android device, then remove it.
- Install the app
set ANDROID_HOME=C:\Users\johan\AppData\Local\Android\Sdk
java -jar c:\dev\bundletool\bundletool-all-1.5.0.jar install-apks --apks=build/app/outputs/bundle/release/thoma5.apks
Step 3. Enroll to Android app store #
- https://play.google.com/console/signup and follow on-screen instructions
Step 4. Create App on Google Play #
- https://play.google.com/console
- Push "Create App" button
- Provide app details and press Create app
Step 5. Provide App policy details #
- https://play.google.com/console
- Select your app
- Select "Policy and programmes" > "App content" and then provide details for all declarations that need attention. You will need:
Step 6. Main store listing #
Step 6.1 Create a feature graphic #
- Create a feature graphic PNG or JPG format 1014 x 500
|
Step 6.2 Take screenshots #
Step 6.2.1 Create virtual machines #
- Start Android Studio
- Select "Tools" > Device Manager
- Select "Create device"
- Press "New Hardware Profile" and create the first hardware profile as listed in the table below
- Press "Next" and select an system image with API level 29
- Allow all default settings and press "Finish"
Name | Device type | Screen size | Resolution | RAM | Has Hardware Buttons | Has Harware Keyboard | Navigation Style |
---|---|---|---|---|---|---|---|
Phone 16:9 | Phone/Tablet | 5.96" | 1440 x 2560 | 2048 MB | / | / | / |
Tablet 7" inch 16:9 | Phone/Tablet | 7" | 1024 x 576 | 2048 MB | / | / | / |
Tablet 10" inch 16:9 | Phone/Tablet | 10" | 3200 x 1800 | 2048 MB | / | / | / |
Step 6.2.2 Run the app and take screenshots #
-
From Android Studio, run your app on the abvove virtual machines
-
Take take 2-8 screenshots from the phone and 1-8 screenshots from each of the 2 tablets
|
Step 6.2.3 Create icon 512 x 512 pixels #
Provide a <a href="logo>logo png file with resolution 512 x 512
|
Step 6.3 Submit main store listing details #
- https://play.google.com/console
- Select your app
- Select "Grow" > "Main store listing"
- Provide your app name, i.e. your app nickname
- Provide a short and full description
- Provide your app icon, i.e. Logo
- Provide your feature graphic, i.e. Feature graphic
- Provide screenshots for phone, 7-inch and 10-inch tablet, i.e. Android screenshots
Step 7. Store settings #
- https://play.google.com/console
- Select your app
- Select "Grow" > "Store settings"
- Press "Edit" in "App category", provide App and select a category, here "Education"
- Press "Save", then close
- Press "Edit" in "Store listing contact details" and provide your a. Email address: google account, here thoma5.com.info@gmail.com b. Optionally your phone number c. Optionally your website, e.g. your domain prefixed with https://, here https://thoma5.com
- Press "Save", then close
Step 8. Countries/regions #
- https://play.google.com/console
- Select your app
- Select "Release" > "Production"
- Select "Countries/regions"
- Select "Add countries/regions"
- Check All countries
- Press "Save"
Step 9. Upload for production #
- https://play.google.com/console
- Select your app
- Select "Release" > "Production"
- Press "Create new release"
- Press "Choose signing key", then select "Use Google-generated key"
- Press "Upload" from "App bundles" then select your Android bundle, here build\app\outputs\bundle\release\app-release.aab
- Provide a release name, e.g. "1 (1.0.0)"
- Provide release notes, e.g.
<en-GB>
First release
</en-GB>
- Press "Next"
- Press "Save"
Step 10: Publishing overview #
- Press the "Send n changes for review"
- Congratulations. Now you just have to wait for the app to be approved.
Chapter V. Deploy to apple store #
Step 1: Enroll for the Apple Developer Program. #
- Goto https://developer.apple.com/programs/enroll/ and follow onscreen instructions to enroll for the Apple Developer Program.
Step 2: Create an app on App Store Connect #
TODO:
- https://appstoreconnect.apple.com/apps
- Select '+' and select 'New app'
- Specity Name: Minkey
- Primary language: English
- Bundle ID: select your App Bunble ID
- SKU: io.minkey.minkeyios
- User Access: Full Access
Step 3: Create simulators #
- iPhone 6.7", iPhone 14 Pro Max - Ok
- iPhone 6.5" --> Use 6.7" Display - Ok
- iPhone 5.5", iPhone 8 plus - Ok
- iPad pro 6th gen 12.9" - Ok
- iPad pro 2nd gen 12.9"
Step 4: Create screenshots #
Step 5: Provide app detailks #
Upload screenshots - For the ipad pro 2nd generation, open terminal and run: sudo xcrun simctl create "iPad Pro (12.9-inch) (2nd generation)" "com.apple.CoreSimulator.SimDeviceType.iPad-Pro--12-9-inch---2nd-generation-" - XCode > Open Developer Tool > Simulator - File > Open Simulator or, if required, New Simulator (to create one of the below) - iPhone 6.7", iPhone 14 Pro Max - Ok - iPhone 6.5" --> Use 6.7" Display - Ok - iPhone 5.5", iPhone 8 plus - Ok - iPad pro 6th gen 12.9" - Ok - iPad pro 2nd gen 12.9" Provide Promotional Text Provide Description Provide Contact Information Provide Sign-in, if required juuwle.net@gmail.com Juuiop857! Save
Step 6: Provide App Privacy details #
Step 7: Create a build archive #
cd apps/minkey_mac/ios flutter build ipa --no-tree-shake-icons
Step 8: Upload to App Store Connect #
Option 1: Use upload tool
- Create and download a key https://developer.apple.com/documentation/appstoreconnectapi/creating_api_keys_for_app_store_connect_api
copy the key into ~/private_keys
(stored in repository keys/AuthKey_TV4KGWA74M.p8)
- Upload find the issuer ID and key ID and on the keys page
then run xcrun altool --upload-app --type ios -f build/ios/ipa/*.ipa --apiKey your_api_key --apiIssuer your_issuer_id
Option 2: Transport app
install/open Transport app on the macbook drag and drop the build/ios/ipa/*.ipa app bundle onto the Apple Transport app
Step 10: Release your app to the App Store #
TODO
TODO: MIGHT NEED TO CHECK WHAT ELSE IN deploy-to-apple-store.txt
Chapter VI. Extend the app with other packages #
TODO
Include extra packages and run wizards. For example, for thoma5 we added: eliud.registerPackage(ChatPackage.instance()); eliud.registerPackage(FeedPackage.instance());
See overview of and links to all currently known packages below.
Chapter VII. Write and integrate your own code / packages #
TODO
Appendix A. Overview packages #
The dependencies of a typical app #
A typical app, here Minkey, uses the following dependencies:
Links #
Package | Description |
---|---|
eliud_core | This package |
eliud_generator | Eliud generator |
eliud_pkg_apps | Eliud package for creating apps through code, not gui |
eliud_pkg_chat | Eliud chat package |
eliud_pkg_create | Eliud create package |
eliud_pkg_etc | Eliud etc package |
eliud_pkg_feed | Eliud feed package |
eliud_pkg_follow | Eliud follow package |
eliud_pkg_fundamentals | Eliud fundamentals package |
eliud_pkg_medium | Eliud medium package |
eliud_pkg_membership | Eliud membership package |
eliud_pkg_notifications | Eliud notifications package |
eliud_pkg_pay | Eliud pay package |
eliud_pkg_shop | Eliud shop package |
eliud_pkg_text | Eliud text package |
eliud_pkg_wizards | Eliud wizards package |
eliud_pkg_workflow | Eliud workflow package |
eliud_stl_mona | Eliud mona style |