DevCommand constructor

DevCommand({
  1. required ConstructEntrypointHandler generator,
  2. required Logger logger,
  3. required FileSystem fs,
})

Implementation

DevCommand({
  required ConstructEntrypointHandler generator,
  required this.logger,
  required this.fs,
}) : _generator = generator {
  argParser
    ..addFlag(
      'recompile',
      help:
          'Re-compiles the construct kernel. '
          'Needed to sync changes for a local construct.',
      negatable: false,
    )
    ..addFlag(
      'skip-if-fresh',
      help:
          'Skip kernel + construct generation when `.revali` outputs are '
          'newer than package sources.',
      negatable: false,
    );

  sharedDevFlags.declareAll(argParser);

  argParser
    ..addFlag(
      'inspect',
      help:
          'Record recent requests to .revali/inspect/requests.jsonl '
          '(sets REVALI_INSPECT / REVALI_INSPECT_LOG)',
      negatable: false,
    )
    ..addOption(
      'cert',
      help:
          'Path to a TLS certificate chain (PEM). Binds the server with '
          'HTTPS. Must be passed together with --key.',
      valueHelp: 'certificates/localhost.pem',
    )
    ..addOption(
      'key',
      help:
          'Path to the TLS private key (PEM) matching --cert. '
          'Must be passed together with --cert.',
      valueHelp: 'certificates/localhost-key.pem',
    );
}