Files
nixpkgs/pkgs/development/python-modules/msoffcrypto-tool/default.nix
T
2026-01-12 23:23:23 +01:00

50 lines
1.1 KiB
Nix

{
lib,
olefile,
buildPythonPackage,
fetchFromGitHub,
poetry-core,
cryptography,
pytestCheckHook,
setuptools,
}:
buildPythonPackage (finalAttrs: {
pname = "msoffcrypto-tool";
version = "6.0.0";
pyproject = true;
src = fetchFromGitHub {
owner = "nolze";
repo = "msoffcrypto-tool";
tag = "v${finalAttrs.version}";
hash = "sha256-qhnQXLkEeMfuPl2FJGX19M2B+StlzGU/wHgmRn9jcxc=";
};
build-system = [ poetry-core ];
dependencies = [
cryptography
olefile
setuptools
];
nativeCheckInputs = [ pytestCheckHook ];
disabledTests = [
# Test fails with AssertionError
"test_cli"
];
pythonImportsCheck = [ "msoffcrypto" ];
meta = {
description = "Python tool and library for decrypting MS Office files with passwords or other keys";
homepage = "https://github.com/nolze/msoffcrypto-tool";
changelog = "https://github.com/nolze/msoffcrypto-tool/blob/v${finalAttrs.src.tag}/CHANGELOG.md";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ fab ];
mainProgram = "msoffcrypto-tool";
};
})