checkUpdate method

dynamic checkUpdate()

Implementation

checkUpdate() async {
  final isUpToDate = await pubUpdater.isUpToDate(
    packageName: 'auto_local',
    currentVersion: version,
  );
  if (!isUpToDate) {
    final latestVersion = await pubUpdater.getLatestVersion("auto_local");

    print("\n⚠️ There is a new update".yellow() +
        " $version -> $latestVersion".green());
    print("Run ${"auto_local update".blue().bold()} to update\n");
  }
}