Merge pull request #167624 from dotlambda/yq-improve
This commit is contained in:
commit
9699dc610d
|
@ -4,6 +4,7 @@
|
|||
, substituteAll
|
||||
, argcomplete
|
||||
, pyyaml
|
||||
, toml
|
||||
, xmltodict
|
||||
, jq
|
||||
, setuptools-scm
|
||||
|
@ -26,11 +27,6 @@ buildPythonPackage rec {
|
|||
})
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace test/test.py \
|
||||
--replace "expect_exit_codes={0} if sys.stdin.isatty() else {2}" "expect_exit_codes={0}"
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [
|
||||
setuptools-scm
|
||||
];
|
||||
|
@ -38,6 +34,7 @@ buildPythonPackage rec {
|
|||
propagatedBuildInputs = [
|
||||
pyyaml
|
||||
xmltodict
|
||||
toml
|
||||
argcomplete
|
||||
];
|
||||
|
||||
|
@ -49,13 +46,8 @@ buildPythonPackage rec {
|
|||
|
||||
pythonImportsCheck = [ "yq" ];
|
||||
|
||||
doInstallCheck = true;
|
||||
installCheckPhase = ''
|
||||
echo '{"hello":{"foo":"bar"}}' | $out/bin/yq -y . | grep 'foo: bar'
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Command-line YAML processor - jq wrapper for YAML documents";
|
||||
description = "Command-line YAML/XML/TOML processor - jq wrapper for YAML, XML, TOML documents";
|
||||
homepage = "https://github.com/kislyuk/yq";
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ womfoo SuperSandro2000 ];
|
||||
|
|
Loading…
Reference in a new issue