2024-09-29 12:43:44 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
fetchFromGitHub,
|
|
|
|
stdenv,
|
|
|
|
rustPlatform,
|
|
|
|
pkg-config,
|
|
|
|
cmake,
|
|
|
|
openssl,
|
|
|
|
autoconf,
|
|
|
|
automake,
|
|
|
|
darwin,
|
2024-09-29 12:53:27 +00:00
|
|
|
unstableGitUpdater,
|
|
|
|
sqlite,
|
2022-08-18 21:34:31 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "hebbot";
|
2024-09-29 12:53:27 +00:00
|
|
|
version = "2.1-unstable-2024-09-20";
|
2022-08-18 21:34:31 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "haecker-felix";
|
|
|
|
repo = "hebbot";
|
2024-09-29 12:53:27 +00:00
|
|
|
rev = "4c7152a3ce88ecfbac06f823abd4fd849e0c30d1";
|
|
|
|
hash = "sha256-y+KpxiEzVAggFoPvTOy0IEmAo2V6mOpM0VzEScUOtsM=";
|
2022-08-18 21:34:31 +00:00
|
|
|
};
|
|
|
|
|
2024-09-29 12:53:27 +00:00
|
|
|
cargoHash = "sha256-7AEWQIUHpeK4aNFzzU10YeJErD0fJ6yQSHwFe4utOFo=";
|
2022-08-18 21:34:31 +00:00
|
|
|
|
2024-09-29 12:43:44 +00:00
|
|
|
nativeBuildInputs =
|
|
|
|
[
|
|
|
|
pkg-config
|
|
|
|
cmake
|
|
|
|
]
|
|
|
|
++ lib.optionals stdenv.hostPlatform.isDarwin [
|
|
|
|
autoconf
|
|
|
|
automake
|
|
|
|
];
|
2022-08-18 21:34:31 +00:00
|
|
|
|
2024-09-29 12:53:27 +00:00
|
|
|
buildInputs =
|
|
|
|
[
|
|
|
|
openssl
|
|
|
|
]
|
|
|
|
++ lib.optional stdenv.hostPlatform.isDarwin [
|
|
|
|
darwin.apple_sdk.frameworks.Security
|
|
|
|
darwin.apple_sdk.frameworks.SystemConfiguration
|
|
|
|
];
|
|
|
|
|
|
|
|
env = {
|
|
|
|
OPENSSL_NO_VENDOR = 1;
|
|
|
|
};
|
|
|
|
|
|
|
|
NIX_CFLAGS_LINK = [
|
|
|
|
"-L${lib.getLib openssl}/lib"
|
|
|
|
"-L${lib.getLib sqlite}/lib"
|
|
|
|
];
|
|
|
|
|
|
|
|
passthru.updateScript = unstableGitUpdater { };
|
2022-08-18 21:34:31 +00:00
|
|
|
|
2024-09-29 12:43:44 +00:00
|
|
|
meta = {
|
2022-08-18 21:34:31 +00:00
|
|
|
description = "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}";
|
2024-09-29 12:43:44 +00:00
|
|
|
license = with lib.licenses; [ agpl3Only ];
|
2023-10-29 16:06:24 +00:00
|
|
|
mainProgram = "hebbot";
|
2024-09-29 12:43:44 +00:00
|
|
|
maintainers = with lib.maintainers; [ a-kenji ];
|
2022-08-18 21:34:31 +00:00
|
|
|
};
|
|
|
|
}
|