Skip to content

Commit ac298a1

Browse files
committed
chore: Update generate_screen.dart
1 parent 45870f2 commit ac298a1

File tree

2 files changed

+7
-14
lines changed

2 files changed

+7
-14
lines changed

bin/generate_screen.dart

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
// ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
88
//.title~
99

10-
import 'dart:io' show Directory;
10+
// import 'dart:io' show Directory;
1111

1212
import 'package:df_generate_screen/df_generate_screen.dart';
1313
import 'package:df_log/df_log.dart';
@@ -16,11 +16,10 @@ import 'package:df_log/df_log.dart';
1616

1717
void main(List<String> args) async {
1818
DebugLog.debugOnly = false;
19-
final currentDir = Directory.current.path;
2019
await runGenerateScreensApp([
21-
'-r',
22-
currentDir,
23-
'-s',
20+
'--class-name',
2421
args.first,
22+
'-o',
23+
'.',
2524
]);
2625
}

lib/src/run_generate_screens_app.dart

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -49,27 +49,23 @@ Future<void> runGenerateScreensApp(List<String> args) async {
4949
..addOption(
5050
'bindings-template',
5151
help: 'Bindings template file path.',
52-
defaultsTo: '',
5352
)
5453
..addOption(
5554
'controller-template',
5655
help: 'Controller template file path.',
57-
defaultsTo: '',
5856
)
5957
..addOption(
6058
'view-template',
6159
help: 'View template file path.',
62-
defaultsTo: '',
6360
)
6461
..addOption(
6562
'screen-template',
6663
help: 'Screen template file path.',
67-
defaultsTo: '',
6864
)
6965
..addOption(
7066
'path',
7167
help: 'Screen path.',
72-
defaultsTo: '',
68+
defaultsTo: '.',
7369
)
7470
..addOption(
7571
'is-only-accessible-if-logged-in',
@@ -94,11 +90,9 @@ Future<void> runGenerateScreensApp(List<String> args) async {
9490
..addOption(
9591
'makeup',
9692
help: 'Screen makeup.',
93+
defaultsTo: '',
9794
)
98-
..addOption(
99-
'default-title',
100-
help: 'Screen title.',
101-
)
95+
..addOption('default-title', help: 'Screen title.', defaultsTo: 'Title')
10296
..addOption(
10397
'part-file-dirs',
10498
help: 'Part file directories separated by `&`.',

0 commit comments

Comments
 (0)