pythonPackages.pwntools: add bash completions (#121907)

Also fixed some PR review warnings
This commit is contained in:
Kristoffer Søholm 2021-05-06 22:05:27 +02:00 committed by GitHub
parent 3b3671ba99
commit ae58a56abb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -2,9 +2,7 @@
, buildPythonPackage
, debugger
, fetchPypi
, isPy3k
, Mako
, makeWrapper
, packaging
, pysocks
, pygments
@ -20,7 +18,7 @@
, tox
, unicorn
, intervaltree
, fetchpatch
, installShellFiles
}:
buildPythonPackage rec {
@ -39,6 +37,10 @@ buildPythonPackage rec {
sed -i 's/unicorn>=1.0.2rc1,<1.0.2rc4/unicorn>=1.0.2rc1/' setup.py
'';
nativeBuildInputs = [
installShellFiles
];
propagatedBuildInputs = [
Mako
packaging
@ -60,6 +62,10 @@ buildPythonPackage rec {
doCheck = false; # no setuptools tests for the package
postInstall = ''
installShellCompletion --bash extra/bash_completion.d/shellcraft
'';
postFixup = ''
mkdir -p "$out/bin"
makeWrapper "${debugger}/bin/${lib.strings.getName debugger}" "$out/bin/pwntools-gdb"