更新编译脚本、优化初始化ServerStatus、更改为英文

This commit is contained in:
LollipopKit
2021-10-24 20:48:54 +08:00
parent 554173bda5
commit 07dbab3e09
7 changed files with 38 additions and 28 deletions

View File

@@ -67,8 +67,8 @@ Future<void> updateBuildData() async {
await writeStaicConfigFile(data, 'BuildData', path);
}
void flutterRun() {
Process.start('flutter', ['run'],
void flutterRun(String? mode) {
Process.start('flutter', ['run', mode == null ? '' : '--$mode'],
mode: ProcessStartMode.inheritStdio, runInShell: true);
}
@@ -121,7 +121,7 @@ void main(List<String> args) async {
switch (command) {
case 'run':
return flutterRun();
return flutterRun(args.length == 2 ? args[1] : null);
case 'build':
if (args.length > 1) {
await updateBuildData();