1
0
mirror of https://github.com/kmein/niveum synced 2026-03-16 10:11:08 +01:00

feat(hesychius): add

This commit is contained in:
2022-07-21 20:33:37 +02:00
parent 5a16a90a8a
commit 5bc26ddc12
3 changed files with 28 additions and 3 deletions

View File

@@ -18,6 +18,7 @@ in {
./literature-quote.nix
./astrology.nix
./autorenkalender.nix
./hesychius.nix
./nachtischsatan.nix
./tlg-wotd.nix
<niveum/modules/telegram-bot.nix>

View File

@@ -0,0 +1,24 @@
{
pkgs,
lib,
...
}: let
hesychius = <scripts> + "/hesychius/hesychius.txt";
in {
niveum.telegramBots.hesychius = {
enable = true;
time = "08:00";
token = lib.strings.fileContents <system-secrets/telegram/kmein.token>;
chatIds = ["@HesychiosAlexandreus"];
parseMode = "Markdown";
command = "${pkgs.coreutils}/bin/shuf -n1 ${hesychius}";
};
niveum.passport.services = [
{
title = "Hesychius of Alexandria Bot";
description = "sends a random word from Hesychius of Alexandria's lexicon to Telegram.";
link = "https://t.me/HesychiosAlexandreus";
}
];
}

6
flake.lock generated
View File

@@ -195,11 +195,11 @@
"scripts": {
"flake": false,
"locked": {
"lastModified": 1657447671,
"narHash": "sha256-SjKlNLllYdW/OHLk55hh23E3XsBU+R0Pu18LXfsxgH0=",
"lastModified": 1658427979,
"narHash": "sha256-5W0omdIH6SAZyXSASxdlDK9+u8vbwAlHdh5gAEP+QHQ=",
"owner": "kmein",
"repo": "scripts",
"rev": "0bfb5d29cbd948a82d2a1c274bc0d374a88c9c88",
"rev": "9b945b3f38297b1cbd6a9efe337c0805d6e2997d",
"type": "github"
},
"original": {