Skip to content

Commit

Permalink
renovate: add recommended settings
Browse files Browse the repository at this point in the history
  • Loading branch information
SuperSandro2000 committed Oct 28, 2024
1 parent 1d1ba30 commit 8d1615d
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions modules/renovate.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{ config, lib, libS, ... }:

let
cfg = config.services.renovate;
in
{
options.services.renovate = lib.optionalAttrs (!lib.versionAtLeast lib.version "24.11") {
# TODO: clean up when updating to 24.11
enable = lib.mkOption {
type = lib.types.bool;
default = false;
internal = !(lib.versionAtLeast lib.version "24.11");
};
settings = lib.mkOption {
type = lib.types.freeformSetting;
internal = !(lib.versionAtLeast lib.version "24.11");
};
} // {
recommendedDefaults = libS.mkOpinionatedOption "set recommended default settings";
};

config = lib.mkIf cfg.enable {
services.renovate.settings = {
cachePrivatePackages = true;
configMigration = true;
optimizeForDisabled = true;
persistRepoData = true;
repositoryCache = "enabled";
};
};
}

0 comments on commit 8d1615d

Please sign in to comment.