This is a template for building Flutter applications for Android, which includes basic dynamic themes, theme settings, language settings and GitHub Actions scripts.
Use this template repo, change the name and clone it.
Changing the project name in Flutter involves manually modifying several files. Follow these steps to change the project name:
- Update
pubspec.yaml
: Change thename
property to your new project name.
name: your_new_project_name
- Update
android/app/src/main/res/values/strings.xml
:
Change the app_name
string to your new project name.
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name">Your New App Name</string>
</resources>
- Update package names
Change the package name used in android/app/src/main/kotlin/com/example/template/MainActivity.kt
, as well as the path of it.
Change the namespace
and applicationId
used in the android\app\build.gradle.kts
file.
- Update the imports in
.dart
Change the imports from:
import 'package:flutter_android_template/**.dart';
to:
import 'package:your_new_project_name/**.dart';
Get your .jks
file, create the base64 string of it:
# Unix
base64 -w 0 <Your-Key-Store-Name>.jks
# Windows
[System.Convert]::ToBase64String([System.IO.File]::ReadAllBytes("<Your-Key-Store-Name>.jks"))
In the Secrets and Variables -- Actions
of your GitHub repo, add secrets:
- SIGNING_KEYSTORE: The base64 code created above
- SIGNING_KEYSTORE_PASSWORD: The key store password
- SIGNING_KEY_ALIAS: The alias for the
.jks
file - SIGNING_KEY_PASSWORD: The password for the alias
- MotionEaseTune, A simple application that can prevent you from motion sickness via 100Hz sound.