feat(locate): add timer
All checks were successful
Discord / discord commits (push) Has been skipped

This commit is contained in:
matt1432 2025-02-15 13:50:45 -05:00
parent d172a82805
commit 85cae813e0

View file

@ -29,7 +29,6 @@ in {
locateGroup
];
# TODO: add timer
systemd.services.locate = {
wantedBy = ["default.target"];
serviceConfig = {
@ -41,6 +40,14 @@ in {
};
};
systemd.timers.locate = {
wantedBy = ["timers.target"];
timerConfig = {
Unit = "locate.service";
OnCalendar = "*-*-* *:0/10:50"; # Every 10 minutes
};
};
home-manager.users.${baseCfg.user}.programs.bash.shellAliases = {
locate = "${pkgs.writeShellScriptBin "lct" ''
exec ${locate} -d ${database} "$@" 2> >(grep -v "/var/cache/locatedb")