1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-11-24 19:29:36 +01:00

Add 'nix profile wipe-history' command

This commit is contained in:
Eelco Dolstra 2021-09-14 20:35:12 +02:00
parent f359b9981b
commit 4b738fc7a9
3 changed files with 61 additions and 2 deletions

View file

@ -126,9 +126,9 @@ void deleteGeneration(const Path & profile, GenerationNumber gen)
static void deleteGeneration2(const Path & profile, GenerationNumber gen, bool dryRun)
{
if (dryRun)
printInfo(format("would remove profile version %1%") % gen);
notice("would remove profile version %1%", gen);
else {
printInfo(format("removing profile version %1%") % gen);
notice("removing profile version %1%", gen);
deleteGeneration(profile, gen);
}
}