mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-07-22 08:30:57 +00:00
python3Packages.detect-secrets: separate optional dependencies
This provides the means to install `detect-secrets` without the optional dependencies that have thus far been installed by default. These continue to be installed by default in order to not break any existing usage.
This commit is contained in:
@@ -13,6 +13,8 @@
|
||||
setuptools,
|
||||
unidiff,
|
||||
writableTmpDirAsHomeHook,
|
||||
withGibberish ? true,
|
||||
withWordList ? true,
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
@@ -31,11 +33,20 @@ buildPythonPackage rec {
|
||||
build-system = [ setuptools ];
|
||||
|
||||
dependencies = [
|
||||
gibberish-detector
|
||||
pyyaml
|
||||
pyahocorasick
|
||||
requests
|
||||
];
|
||||
]
|
||||
++ lib.optionals withGibberish optional-dependencies.gibberish
|
||||
++ lib.optionals withWordList optional-dependencies.word_list;
|
||||
|
||||
optional-dependencies = {
|
||||
gibberish = [
|
||||
gibberish-detector
|
||||
];
|
||||
word_list = [
|
||||
pyahocorasick
|
||||
];
|
||||
};
|
||||
|
||||
nativeCheckInputs = [
|
||||
mock
|
||||
|
||||
Reference in New Issue
Block a user