Skip to content

Commit

Permalink
Better output messages when disabling auto-purge
Browse files Browse the repository at this point in the history
  • Loading branch information
macCesar committed Dec 1, 2021
1 parent ee8ce00 commit 8a23826
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -537,13 +537,14 @@ function removeHook() {
if (!line.includes("require('child_process').execSync('purgetss")) {
updatedJMKFile.push(line);
} else if (!line.includes("//")) {
// if not disabled, disable it!!
updatedJMKFile.push(`\t//${line}`);
logger.warn(chalk.yellow('Auto-Purging hook disabled!'));
} else {
logger.warn(chalk.red('Auto-Purging hook removed!'));
logger.warn(chalk.red('It will be added the next time `PurgeTSS` runs!'));
}
});

logger.warn(chalk.red('Auto-Purging hook removed!'));

saveFile(destJMKFile, updatedJMKFile.join("\n"));
}
}
Expand Down

0 comments on commit 8a23826

Please sign in to comment.