53 std::filesystem::path
path;
85std::pair<Generations, std::optional<GenerationNumber>>
findGenerations(std::filesystem::path profile);
133 const std::filesystem::path & profile,
const std::set<GenerationNumber> & gensToDelete,
bool dryRun);
185void switchLink(std::filesystem::path link, std::filesystem::path target);
191void switchGeneration(
const std::filesystem::path & profile, std::optional<GenerationNumber> dstGen,
bool dryRun);
210std::string optimisticLockProfile(
const std::filesystem::path & profile);
212struct ProfileDirsOptions
214 const std::filesystem::path & nixStateDir;
215 bool useXDGBaseDirectories;
222std::filesystem::path profilesDir(ProfileDirsOptions opts);
227std::filesystem::path rootProfilesDir(ProfileDirsOptions opts);
232std::filesystem::path defaultChannelsDir(ProfileDirsOptions opts);
237std::filesystem::path rootChannelsDir(ProfileDirsOptions opts);
244std::filesystem::path getDefaultProfile(ProfileDirsOptions opts);
Definition pathlocks.hh:27
void deleteGenerations(const std::filesystem::path &profile, const std::set< GenerationNumber > &gensToDelete, bool dryRun)
Definition profiles.cc:123
void deleteOldGenerations(const std::filesystem::path &profile, bool dryRun)
Definition profiles.cc:175
void switchGeneration(const std::filesystem::path &profile, std::optional< GenerationNumber > dstGen, bool dryRun)
Definition profiles.cc:252
void deleteGeneration(const std::filesystem::path &profile, GenerationNumber gen)
Definition profiles.cc:98
void lockProfile(PathLocks &lock, const std::filesystem::path &profile)
Definition profiles.cc:279
void deleteGenerationsOlderThan(const std::filesystem::path &profile, time_t t, bool dryRun)
Definition profiles.cc:187
std::pair< Generations, std::optional< GenerationNumber > > findGenerations(std::filesystem::path profile)
std::list< Generation > Generations
Definition profiles.hh:66
uint64_t GenerationNumber
Definition profiles.hh:27
void switchLink(std::filesystem::path link, std::filesystem::path target)
Definition profiles.cc:243
void deleteGenerationsGreaterThan(const std::filesystem::path &profile, GenerationNumber max, bool dryRun)
Definition profiles.cc:150
time_t parseOlderThanTimeSpec(std::string_view timeSpec)
Definition profiles.cc:228
std::filesystem::path createGeneration(LocalFSStore &store, std::filesystem::path profile, StorePath outPath)
Definition profiles.cc:61
Definition profiles.hh:36
std::filesystem::path path
Definition profiles.hh:53
time_t creationTime
Definition profiles.hh:60
GenerationNumber number
Definition profiles.hh:41
Definition local-fs-store.hh:91