generateEntrypoint method

void generateEntrypoint(
  1. SidekickTemplateProperties props
)

Implementation

void generateEntrypoint(SidekickTemplateProperties props) {
  final path = relative(
    props.packageLocation.path,
    from: props.entrypointLocation.parent.path,
  );
  final entrypoint = entrypointTemplate(packagePath: path);
  props.entrypointLocation.writeAsStringSync(entrypoint);
  props.entrypointLocation.makeExecutable();
}