prepareReleaseNotes method

void prepareReleaseNotes(
  1. String projectRootPath,
  2. Version newVersion,
  3. Version? currentVersion, {
  4. required bool usingGit,
  5. required bool autoAnswer,
  6. required bool dryrun,
})

Implementation

void prepareReleaseNotes(
    String projectRootPath, Version newVersion, Version? currentVersion,
    {required bool usingGit,
    required bool autoAnswer,
    required bool dryrun}) {
  /// the change log is backed up as part of the dry run
  /// and restored afterwoods.
  if (!doReleaseNotesExist(newVersion)) {
    print('Generating release notes.');
    generateReleaseNotes(newVersion, currentVersion,
        autoAnswer: autoAnswer, dryrun: dryrun);
    if (!dryrun && usingGit) {
      // final git = Git(projectRootPath);
      // print('Committing release notes and versioned files');
      // git.commitVersion("Released $newVersion");

      // if (git.hasRemote) {
      //   git.push();
      // }
    }
  }
  //}
}