summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--default.nix1
-rw-r--r--pkgs/lightnovel-crawler.nix56
2 files changed, 57 insertions, 0 deletions
diff --git a/default.nix b/default.nix
index a834752..4c0b1ab 100644
--- a/default.nix
+++ b/default.nix
@@ -34,6 +34,7 @@ let
};
sorremacs = callPackage ./pkgs/sorremacs { };
+ lightnovel-crawler = callPackage ./pkgs/lightnovel-crawler.nix { };
};
in
{
diff --git a/pkgs/lightnovel-crawler.nix b/pkgs/lightnovel-crawler.nix
new file mode 100644
index 0000000..dcdd1bd
--- /dev/null
+++ b/pkgs/lightnovel-crawler.nix
@@ -0,0 +1,56 @@
+{
+ lib,
+ python3Packages,
+ fetchFromGitHub,
+}:
+python3Packages.buildPythonApplication rec {
+ pname = "lightnovel-crawler";
+ version = "3.7.5";
+ # NOTE: the project uses a plain setup.py, but setting this is still recommended
+ # see: https://nixos.org/manual/nixpkgs/stable/#buildpythonpackage-parameters
+ pyproject = true;
+
+ src = fetchFromGitHub {
+ owner = "dipu-bd";
+ repo = "lightnovel-crawler";
+ rev = "v${version}";
+ sha256 = "sha256-aYnx+t8DkSty9Kdz+NxYEQWiMFpJ6/5xWNpKkvcnkR8=";
+ };
+
+ build-system = with python3Packages; [
+ setuptools
+ ];
+
+ dependencies = with python3Packages; [
+ ascii
+ regex
+ pyease-grpc
+ python-dotenv
+ beautifulsoup4
+ requests
+ python-slugify
+ colorama
+ tqdm
+ pyexecjs
+ ebooklib
+ pillow
+ cloudscraper
+ lxml
+ lxml-html-clean
+ readability-lxml
+ questionary
+ prompt-toolkit
+ html5lib
+ base58
+ python-box
+ pycryptodome
+ selenium
+ packaging
+ ];
+
+ meta = {
+ homepage = "https://github.com/dipu-bd/lightnovel-crawler";
+ description = "Generate and download e-books from online sources";
+ license = lib.licenses.gpl3;
+ };
+}