mnamer: init at 2.5.3
This commit is contained in:
parent
4711f4b61e
commit
0ef6841aaa
46
pkgs/applications/misc/mnamer/default.nix
Normal file
46
pkgs/applications/misc/mnamer/default.nix
Normal file
@ -0,0 +1,46 @@
|
||||
{ python3Packages, fetchFromGitHub, lib }:
|
||||
|
||||
python3Packages.buildPythonApplication rec {
|
||||
pname = "mnamer";
|
||||
version = "2.5.3";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "jkwill87";
|
||||
repo = "mnamer";
|
||||
rev = version;
|
||||
sha256 = "1frrvfhp85fh82yw9yb6n61by8qp1v7f3c0f623njxk1afawhccd";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = with python3Packages; [
|
||||
babelfish
|
||||
requests
|
||||
appdirs
|
||||
teletype
|
||||
requests-cache
|
||||
guessit
|
||||
];
|
||||
|
||||
patches = [
|
||||
# requires specific old versions of dependencies which have been updated in nixpkgs
|
||||
./remove_requirements.patch
|
||||
|
||||
# author reads a private property that changed between versions
|
||||
./update_hack.patch
|
||||
];
|
||||
|
||||
checkInputs = [ python3Packages.pytestCheckHook ];
|
||||
|
||||
# disable test that fail (networking, etc)
|
||||
disabledTests = [
|
||||
"network"
|
||||
"e2e"
|
||||
"test_utils.py"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/jkwill87/mnamer";
|
||||
description = "An intelligent and highly configurable media organization utility";
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ urlordjames ];
|
||||
};
|
||||
}
|
21
pkgs/applications/misc/mnamer/remove_requirements.patch
Normal file
21
pkgs/applications/misc/mnamer/remove_requirements.patch
Normal file
@ -0,0 +1,21 @@
|
||||
diff --git a/setup.py b/setup.py
|
||||
index 245c1dd..fdc17ab 100755
|
||||
--- a/setup.py
|
||||
+++ b/setup.py
|
||||
@@ -7,16 +7,12 @@ from mnamer.__version__ import VERSION
|
||||
with open("readme.md", "r", encoding="utf8") as fp:
|
||||
LONG_DESCRIPTION = fp.read()
|
||||
|
||||
-with open("requirements.txt", "r", encoding="utf8") as fp:
|
||||
- REQUIREMENTS = fp.read().splitlines()
|
||||
-
|
||||
setup(
|
||||
author="Jessy Williams",
|
||||
author_email="jessy@jessywilliams.com",
|
||||
description="A media file organiser",
|
||||
entry_points={"console_scripts": ["mnamer=mnamer.__main__:main"]},
|
||||
include_package_data=True,
|
||||
- install_requires=REQUIREMENTS,
|
||||
license="MIT",
|
||||
long_description=LONG_DESCRIPTION,
|
||||
long_description_content_type="text/markdown",
|
13
pkgs/applications/misc/mnamer/update_hack.patch
Normal file
13
pkgs/applications/misc/mnamer/update_hack.patch
Normal file
@ -0,0 +1,13 @@
|
||||
diff --git a/mnamer/utils.py b/mnamer/utils.py
|
||||
index 636b596..e52bd37 100644
|
||||
--- a/mnamer/utils.py
|
||||
+++ b/mnamer/utils.py
|
||||
@@ -280,7 +280,7 @@ def request_json(
|
||||
"like Gecko) Chrome/79.0.3945.88 Safari/537.36"
|
||||
)
|
||||
|
||||
- initial_cache_state = session._is_cache_disabled # yes, i'm a bad person
|
||||
+ initial_cache_state = session._disabled # yes, i'm a bad person
|
||||
try:
|
||||
session._is_cache_disabled = not cache
|
||||
response = session.request(
|
@ -25662,6 +25662,8 @@ in
|
||||
|
||||
mmtc = callPackage ../applications/audio/mmtc { };
|
||||
|
||||
mnamer = callPackage ../applications/misc/mnamer { };
|
||||
|
||||
moc = callPackage ../applications/audio/moc { };
|
||||
|
||||
mod-distortion = callPackage ../applications/audio/mod-distortion { };
|
||||
|
Loading…
Reference in New Issue
Block a user