diff --git a/modules/telegram-bot.nix b/modules/telegram-bot.nix index d58e021..28f8e47 100644 --- a/modules/telegram-bot.nix +++ b/modules/telegram-bot.nix @@ -8,10 +8,10 @@ let startAt = bot.time; serviceConfig.Type = "oneshot"; wants = [ "network-online.target" ]; - script = strings.concatStringsSep "\n" (map (chatId: '' + script = strings.concatStringsSep "\n" (["QUOTE=$(${bot.command})"] ++ map (chatId: '' ${pkgs.curl}/bin/curl -s -X POST "https://api.telegram.org/bot${bot.token}/sendMessage" \ -d chat_id="${chatId}" \ - -d text="$(${bot.command})" ${ + -d text="$QUOTE" ${ if bot.parseMode == null then "" else "-d parse_mode=${bot.parseMode}" } diff --git a/systems/catullus/containers.nix b/systems/catullus/containers.nix index 9573404..f29791b 100644 --- a/systems/catullus/containers.nix +++ b/systems/catullus/containers.nix @@ -14,7 +14,7 @@ in { enable = true; time = "08/6:00"; token = lib.strings.removeSuffix "\n" (builtins.readFile ); - chatIds = [ "18980945" ]; + chatIds = [ "18980945" "757821027" ]; command = "${pkgs.literature-quote}/bin/literature-quote"; parseMode = "Markdown"; };