about summary refs log tree commit diff
diff options
context:
space:
mode:
authora-kenji <aks.kenji@protonmail.com>2022-08-18 23:34:31 +0200
committerGitHub <noreply@github.com>2022-08-18 23:34:31 +0200
commit7e533d199f5956f776686439f8006c2aa04b5461 (patch)
treea0382b448cf754320a89d56471ad3b29e307c7f7
parentf994d00dafef6ec634d48db383f99597cc1d720d (diff)
hebbot: init at 2.1 (#187178)
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
-rw-r--r--maintainers/maintainer-list.nix6
-rw-r--r--pkgs/servers/matrix-hebbot/default.nix39
-rw-r--r--pkgs/top-level/all-packages.nix4
3 files changed, 49 insertions, 0 deletions
diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix
index 2a13a6c429b7d..be0cfb4930cac 100644
--- a/maintainers/maintainer-list.nix
+++ b/maintainers/maintainer-list.nix
@@ -1359,6 +1359,12 @@
     githubId = 9315;
     name = "Zhong Jianxin";
   };
+  a-kenji = {
+    email = "aks.kenji@protonmail.com";
+    github = "a-kenji";
+    githubId = 65275785;
+    name = "Alexander Kenji Berthold";
+  };
   b4dm4n = {
     email = "fabianm88@gmail.com";
     github = "B4dM4n";
diff --git a/pkgs/servers/matrix-hebbot/default.nix b/pkgs/servers/matrix-hebbot/default.nix
new file mode 100644
index 0000000000000..e84339e9f330a
--- /dev/null
+++ b/pkgs/servers/matrix-hebbot/default.nix
@@ -0,0 +1,39 @@
+{ lib
+, fetchFromGitHub
+, pkgs
+, stdenv
+, rustPlatform
+, pkg-config
+, cmake
+, openssl
+, autoconf
+, automake
+, Security
+}:
+
+rustPlatform.buildRustPackage rec {
+  pname = "hebbot";
+  version = "2.1";
+
+  src = fetchFromGitHub {
+    owner = "haecker-felix";
+    repo = "hebbot";
+    rev = "v${version}";
+    sha256 = "sha256-zcsoTWpNonkgJLTC8S9Nubnzdhj5ROL/UGNWUsLxLgs=";
+  };
+
+  cargoSha256 = "sha256-ZNETA2JUZCS8/a2oeF+JCGVKbzeyhp51D0BmBTPToOw=";
+
+  nativeBuildInputs = [ pkg-config cmake ] ++
+    lib.optionals stdenv.isDarwin [ autoconf automake ];
+
+  buildInputs = [ openssl ] ++ lib.optional stdenv.isDarwin Security;
+
+  meta = with lib; {
+    description = "A Matrix bot which can generate \"This Week in X\" like blog posts ";
+    homepage = "https://github.com/haecker-felix/hebbot";
+    changelog = "https://github.com/haecker-felix/hebbot/releases/tag/v${version}";
+    license = with licenses; [ agpl3 ];
+    maintainers = with maintainers; [ a-kenji ];
+  };
+}
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index 447c57ec891ea..f0f42fc7ef6da 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -3988,6 +3988,10 @@ with pkgs;
 
   hebcal = callPackage ../tools/misc/hebcal {};
 
+  hebbot = callPackage ../servers/matrix-hebbot {
+    inherit (darwin.apple_sdk.frameworks) Security;
+  };
+
   hexio = callPackage ../development/tools/hexio { };
 
   hexyl = callPackage ../tools/misc/hexyl { };