Merge pull request #170781 from erikarvstedt/papgerless-ngx-1.7.0
paperless-ngx: 1.6.0 -> 1.7.1
This commit is contained in:
commit
c10e14acc7
2 changed files with 20 additions and 8 deletions
|
@ -1,6 +1,5 @@
|
||||||
{ lib
|
{ lib
|
||||||
, fetchurl
|
, fetchurl
|
||||||
, fetchpatch
|
|
||||||
, nixosTests
|
, nixosTests
|
||||||
, python3
|
, python3
|
||||||
, ghostscript
|
, ghostscript
|
||||||
|
@ -15,11 +14,16 @@
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let
|
let
|
||||||
|
# Use specific package versions required by paperless-ngx
|
||||||
py = python3.override {
|
py = python3.override {
|
||||||
packageOverrides = self: super: {
|
packageOverrides = self: super: {
|
||||||
django = super.django_3;
|
django = super.django_4;
|
||||||
|
|
||||||
|
# django-extensions 3.1.5 is required, but its tests are incompatible with Django 4
|
||||||
|
django-extensions = super.django-extensions.overridePythonAttrs (_: {
|
||||||
|
doCheck = false;
|
||||||
|
});
|
||||||
|
|
||||||
# Incompatible with aioredis 2
|
|
||||||
aioredis = super.aioredis.overridePythonAttrs (oldAttrs: rec {
|
aioredis = super.aioredis.overridePythonAttrs (oldAttrs: rec {
|
||||||
version = "1.3.1";
|
version = "1.3.1";
|
||||||
src = oldAttrs.src.override {
|
src = oldAttrs.src.override {
|
||||||
|
@ -34,11 +38,12 @@ let
|
||||||
in
|
in
|
||||||
py.pkgs.pythonPackages.buildPythonApplication rec {
|
py.pkgs.pythonPackages.buildPythonApplication rec {
|
||||||
pname = "paperless-ngx";
|
pname = "paperless-ngx";
|
||||||
version = "1.6.0";
|
version = "1.7.1";
|
||||||
|
|
||||||
|
# Fetch the release tarball instead of a git ref because it contains the prebuilt fontend
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "https://github.com/paperless-ngx/paperless-ngx/releases/download/ngx-${version}/${pname}-${version}.tar.xz";
|
url = "https://github.com/paperless-ngx/paperless-ngx/releases/download/v${version}/${pname}-v${version}.tar.xz";
|
||||||
sha256 = "07mrxbwahkm00n9nvssd6d13p80w333g84cd38bzp0l34nzim5zl";
|
hash = "sha256-8vx4hvbIqaChjPyS8Q0ar2bz/pLzEdxoF7P2gBEeFzc=";
|
||||||
};
|
};
|
||||||
|
|
||||||
format = "other";
|
format = "other";
|
||||||
|
@ -92,6 +97,7 @@ py.pkgs.pythonPackages.buildPythonApplication rec {
|
||||||
numpy
|
numpy
|
||||||
ocrmypdf
|
ocrmypdf
|
||||||
pathvalidate
|
pathvalidate
|
||||||
|
pdf2image
|
||||||
pdfminer-six
|
pdfminer-six
|
||||||
pikepdf
|
pikepdf
|
||||||
pillow
|
pillow
|
||||||
|
@ -109,6 +115,7 @@ py.pkgs.pythonPackages.buildPythonApplication rec {
|
||||||
python-magic
|
python-magic
|
||||||
pytz
|
pytz
|
||||||
pyyaml
|
pyyaml
|
||||||
|
pyzbar
|
||||||
redis
|
redis
|
||||||
regex
|
regex
|
||||||
reportlab
|
reportlab
|
||||||
|
@ -189,6 +196,6 @@ py.pkgs.pythonPackages.buildPythonApplication rec {
|
||||||
description = "A supercharged version of paperless: scan, index, and archive all of your physical documents";
|
description = "A supercharged version of paperless: scan, index, and archive all of your physical documents";
|
||||||
homepage = "https://paperless-ngx.readthedocs.io/en/latest/";
|
homepage = "https://paperless-ngx.readthedocs.io/en/latest/";
|
||||||
license = licenses.gpl3Only;
|
license = licenses.gpl3Only;
|
||||||
maintainers = with maintainers; [ lukegb ];
|
maintainers = with maintainers; [ lukegb gador earvstedt ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,13 +4,18 @@ buildPythonPackage rec {
|
||||||
pname = "pdf2image";
|
pname = "pdf2image";
|
||||||
version = "1.16.0";
|
version = "1.16.0";
|
||||||
|
|
||||||
propagatedBuildInputs = [ pillow poppler_utils ];
|
propagatedBuildInputs = [ pillow ];
|
||||||
|
|
||||||
src = fetchPypi {
|
src = fetchPypi {
|
||||||
inherit pname version;
|
inherit pname version;
|
||||||
sha256 = "d58ed94d978a70c73c2bb7fdf8acbaf2a7089c29ff8141be5f45433c0c4293bb";
|
sha256 = "d58ed94d978a70c73c2bb7fdf8acbaf2a7089c29ff8141be5f45433c0c4293bb";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
postPatch = ''
|
||||||
|
# Only replace first match in file
|
||||||
|
sed -i '0,/poppler_path=None/s||poppler_path="${poppler_utils}/bin"|' pdf2image/pdf2image.py
|
||||||
|
'';
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "A python module that wraps the pdftoppm utility to convert PDF to PIL Image object";
|
description = "A python module that wraps the pdftoppm utility to convert PDF to PIL Image object";
|
||||||
homepage = "https://github.com/Belval/pdf2image";
|
homepage = "https://github.com/Belval/pdf2image";
|
||||||
|
|
Loading…
Reference in a new issue