health reminder syntax fix 2
This commit is contained in:
@@ -12,7 +12,9 @@ lib.mkIf (host != "NxACE")
|
||||
};
|
||||
|
||||
systemd.user.services."health_reminder" = let
|
||||
hm = pkgs.writers.writePython3Bin "health_reminder" {} /*python*/ ''
|
||||
hm = pkgs.writers.writePython3Bin "health_reminder" {
|
||||
flakeIgnore = [ "E302" "E305" "E226" "E501" ];
|
||||
} /*python*/ ''
|
||||
import random
|
||||
import re
|
||||
|
||||
@@ -24,10 +26,10 @@ lib.mkIf (host != "NxACE")
|
||||
|
||||
def __str__(self):
|
||||
try:
|
||||
choice = random.choice(self.options)
|
||||
choice = random.choice(self.options)
|
||||
except IndexError:
|
||||
choice = ""
|
||||
|
||||
|
||||
action = re.sub("%o", choice, self.action)
|
||||
return action
|
||||
|
||||
|
||||
Reference in New Issue
Block a user