mirror of
https://github.com/flutter/flutter
synced 2024-10-13 11:42:54 +00:00
Hide flutter run_mojo
This commit is contained in:
parent
2be0dfd6a0
commit
f784fb8ce6
|
@ -54,7 +54,7 @@ Future main(List<String> args) async {
|
|||
..addCommand(new LogsCommand())
|
||||
..addCommand(new RefreshCommand())
|
||||
..addCommand(new RunCommand())
|
||||
..addCommand(new RunMojoCommand())
|
||||
..addCommand(new RunMojoCommand(hideCommand: !verboseHelp))
|
||||
..addCommand(new StopCommand())
|
||||
..addCommand(new TestCommand())
|
||||
..addCommand(new TraceCommand())
|
||||
|
|
|
@ -28,15 +28,15 @@ const String protocolVersion = '0.1.0';
|
|||
/// It can be shutdown with a `daemon.shutdown` command (or by killing the
|
||||
/// process).
|
||||
class DaemonCommand extends FlutterCommand {
|
||||
DaemonCommand({ this.hideCommand: false });
|
||||
DaemonCommand({ bool hideCommand: false }) : _hideCommand = hideCommand;
|
||||
|
||||
final String name = 'daemon';
|
||||
final String description = 'Run a persistent, JSON-RPC based server to communicate with devices.';
|
||||
final bool hideCommand;
|
||||
final bool _hideCommand;
|
||||
|
||||
bool get requiresProjectRoot => false;
|
||||
|
||||
bool get hidden => hideCommand;
|
||||
bool get hidden => _hideCommand;
|
||||
|
||||
Future<int> runInProject() {
|
||||
printStatus('Starting device daemon...');
|
||||
|
|
|
@ -19,9 +19,10 @@ const String _kDefaultBundlePath = 'build/app.flx';
|
|||
|
||||
class RunMojoCommand extends FlutterCommand {
|
||||
final String name = 'run_mojo';
|
||||
final String description = 'Run a Flutter app in mojo.';
|
||||
final String description = 'Run a Flutter app in mojo (from github.com/domokit/mojo).';
|
||||
final bool _hideCommand;
|
||||
|
||||
RunMojoCommand() {
|
||||
RunMojoCommand({ hideCommand: false }) : _hideCommand = hideCommand {
|
||||
argParser.addFlag('android', negatable: false, help: 'Run on an Android device');
|
||||
argParser.addFlag('checked', negatable: false, help: 'Run Flutter in checked mode');
|
||||
argParser.addFlag('mojo-debug', negatable: false, help: 'Use Debug build of mojo');
|
||||
|
@ -37,6 +38,7 @@ class RunMojoCommand extends FlutterCommand {
|
|||
}
|
||||
|
||||
bool get requiresProjectRoot => false;
|
||||
bool get hidden => _hideCommand;
|
||||
|
||||
// TODO(abarth): Why not use path.absolute?
|
||||
String _makePathAbsolute(String relativePath) {
|
||||
|
|
Loading…
Reference in a new issue