diff options
| author | 2025-12-11 19:45:30 +0000 | |
|---|---|---|
| committer | 2025-12-11 19:51:28 +0000 | |
| commit | 9f5d340d1ef627e6d9350cf31b89e62868f30b02 (patch) | |
| tree | 86c7a7d2c75ffade2a428524188187caf8547d77 /pkgs/pywikibot-scripts | |
| parent | try to deflakify it (broken commit) (diff) | |
| signature | ||
try to make scripts work in nix
the wrapper is annoying me
Diffstat (limited to 'pkgs/pywikibot-scripts')
| -rw-r--r-- | pkgs/pywikibot-scripts/default.nix | 22 | ||||
| -rw-r--r-- | pkgs/pywikibot-scripts/setup.py | 18 |
2 files changed, 29 insertions, 11 deletions
diff --git a/pkgs/pywikibot-scripts/default.nix b/pkgs/pywikibot-scripts/default.nix index d5ea238..584ad28 100644 --- a/pkgs/pywikibot-scripts/default.nix +++ b/pkgs/pywikibot-scripts/default.nix @@ -1,34 +1,34 @@ { lib, fetchgit, + python3, python3Packages, + stdenv, }: python3Packages.buildPythonPackage rec { - pname = "pywikibot-scripts"; + pname = "scripts"; version = "10.7.0"; - format = "pyproject"; + pyproject = true; + build-system = [ python3Packages.setuptools ]; disabled = python3Packages.pythonOlder "3.8"; src = fetchgit { url = "https://gerrit.wikimedia.org/r/pywikibot/core"; rev = "f1b4b4d0cfbc199c36fb72570425328daa93b067"; - sparseCheckout = [ "pywikibot/scripts" "scripts" ]; fetchSubmodules = true; - hash = "sha256-MXwrn3WLWmddZRKNryELDRlKmqCqj/6WGDJJbnRAiZs="; + hash = "sha256-L/Yz9yidpTV7WCqHs2L6lFw/CpQyZ1UNd+NpMLJT0Hs="; }; - propagatedBuildInputs = [ - python3Packages.mwparserfromhell - python3Packages.requests - python3Packages.setuptools - ]; + postPatch = '' + rm pyproject.toml setup.py + cp ${./setup.py} ./setup.py + ''; - # Tests attempt to install a tool using pip, which fails due to the sandbox doCheck = false; - pythonImportsCheck = [ "pywikibot.scripts" ]; + pythonImportsCheck = [ "scripts" ]; meta = { description = "Python MediaWiki bot framework scripts"; diff --git a/pkgs/pywikibot-scripts/setup.py b/pkgs/pywikibot-scripts/setup.py new file mode 100644 index 0000000..7f00ffc --- /dev/null +++ b/pkgs/pywikibot-scripts/setup.py @@ -0,0 +1,18 @@ +from setuptools import setup + +setup(**{ + 'name': 'scripts', + 'version': '0.0.0', + 'description': 'Scripts from pywikibot', + 'long_description': None, + 'author': None, + 'author_email': None, + 'maintainer': None, + 'maintainer_email': None, + 'url': None, + 'packages': ['scripts'], + 'package_data': {'': ['*']}, + 'install_requires': [], + 'entry_points': {}, + 'python_requires': '', +}) |
