2023-04-29 16:46:19 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, installShellFiles, python3, git, git-annex }:
|
2022-06-16 17:23:12 +00:00
|
|
|
|
|
|
|
python3.pkgs.buildPythonApplication rec {
|
|
|
|
pname = "datalad";
|
2023-04-29 16:46:19 +00:00
|
|
|
version = "0.18.3";
|
2022-06-16 17:23:12 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "datalad";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2023-04-29 16:46:19 +00:00
|
|
|
hash = "sha256-vqO37o5NxQk+gHfvhM1I2ea9/q9ZaLWkDEyPYJKEPcs";
|
2022-06-16 17:23:12 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ installShellFiles git ];
|
|
|
|
|
|
|
|
propagatedBuildInputs = with python3.pkgs; [
|
|
|
|
# core
|
|
|
|
platformdirs
|
|
|
|
chardet
|
|
|
|
iso8601
|
|
|
|
humanize
|
|
|
|
fasteners
|
|
|
|
packaging
|
|
|
|
patool
|
|
|
|
tqdm
|
|
|
|
annexremote
|
2023-04-29 16:46:19 +00:00
|
|
|
looseversion
|
|
|
|
setuptools
|
|
|
|
git-annex
|
2022-06-16 17:23:12 +00:00
|
|
|
|
|
|
|
# downloaders-extra
|
|
|
|
# requests-ftp # not in nixpkgs yet
|
|
|
|
|
|
|
|
# downloaders
|
|
|
|
boto
|
|
|
|
keyrings-alt
|
|
|
|
keyring
|
|
|
|
msgpack
|
|
|
|
requests
|
|
|
|
|
|
|
|
# publish
|
|
|
|
python-gitlab
|
|
|
|
|
|
|
|
# misc
|
|
|
|
argcomplete
|
|
|
|
pyperclip
|
|
|
|
python-dateutil
|
|
|
|
|
|
|
|
# metadata
|
|
|
|
simplejson
|
|
|
|
whoosh
|
|
|
|
|
|
|
|
# metadata-extra
|
|
|
|
pyyaml
|
|
|
|
mutagen
|
|
|
|
exifread
|
|
|
|
python-xmp-toolkit
|
|
|
|
pillow
|
|
|
|
|
|
|
|
# duecredit
|
|
|
|
duecredit
|
|
|
|
|
|
|
|
# python>=3.8
|
|
|
|
distro
|
2022-10-30 15:09:59 +00:00
|
|
|
] ++ lib.optionals stdenv.hostPlatform.isWindows [ colorama ]
|
|
|
|
++ lib.optionals (python3.pythonOlder "3.10") [ importlib-metadata ];
|
2022-06-16 17:23:12 +00:00
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
installShellCompletion --cmd datalad \
|
|
|
|
--bash <($out/bin/datalad shell-completion) \
|
|
|
|
--zsh <($out/bin/datalad shell-completion)
|
2023-04-29 16:46:19 +00:00
|
|
|
wrapProgram $out/bin/datalad --prefix PYTHONPATH : "$PYTHONPATH"
|
2022-06-16 17:23:12 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
# no tests
|
|
|
|
doCheck = false;
|
|
|
|
|
2023-04-29 16:46:19 +00:00
|
|
|
pythonImportsCheck = [ "datalad" ];
|
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Keep code, data, containers under control with git and git-annex";
|
|
|
|
homepage = "https://www.datalad.org";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ renesat ];
|
|
|
|
};
|
|
|
|
}
|