~emersion/goguma-dev

tool/gen_main: Fix import order v1 SUPERSEDED

delthas: 1
 tool/gen_main: Fix import order

 1 files changed, 2 insertions(+), 2 deletions(-)
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~emersion/goguma-dev/patches/51339/mbox | git am -3
Learn more about email & git

[PATCH v1] tool/gen_main: Fix import order Export this patch

This makes my linter happier :-)
---
 tool/gen_main.dart | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tool/gen_main.dart b/tool/gen_main.dart
index 049d724..456f706 100644
--- a/tool/gen_main.dart
+++ b/tool/gen_main.dart
@@ -47,7 +47,9 @@ void main(List<String> args) async {
		var apiKey = data['client'][0]['api_key'][0]['current_key'] as String;

		imports += '''import 'package:firebase_core/firebase_core.dart';

import 'firebase.dart';
import 'main.dart' as base;
''';
		body += '''	base.initPush = wrapFirebaseInitPush(base.initPush, const FirebaseOptions(
		apiKey: '$apiKey',
@@ -59,8 +61,6 @@ import 'firebase.dart';
	}

	var gen = '''// This file has been generated by gen_main.dart - DO NOT EDIT
import 'main.dart' as base;

$imports
void main() {
$body

base-commit: 6dc63b850b80e21b7d9bd184cd3765e4b2b24954
-- 
2.44.0
Unfortunately this isn't functionally equivalent: the main import is now
in the conditional, and missing when Firebase is disabled.