Files
nixpkgs/pkgs/by-name/cr/crudini/package.nix
Michael Daniels 075e8c2c4f treewide: change 'format = "pyproject";' to 'pyproject = true;'
This is almost all find-and-replace.

I manually edited:
* pkgs/development/python-modules/notifications-android-tv/default.nix,
* pkgs/servers/home-assistant/default.nix,
* pkgs/development/tools/continuous-integration/buildbot/master.nix

A few files have not been changed in this PR because they would cause rebuilds.

This PR should have 0 rebuilds.
2026-01-12 17:50:35 -05:00

61 lines
1.2 KiB
Nix

{
lib,
fetchFromGitHub,
python3Packages,
help2man,
installShellFiles,
}:
python3Packages.buildPythonApplication rec {
pname = "crudini";
version = "0.9.6";
pyproject = true;
src = fetchFromGitHub {
owner = "pixelb";
repo = "crudini";
tag = version;
hash = "sha256-XW9pdP+aie6v9h35gLYM0wVrcsh+dcEB7EueATOV4w4=";
};
postPatch = ''
patchShebangs crudini.py crudini-help tests/test.sh
'';
nativeBuildInputs = [
help2man
installShellFiles
python3Packages.setuptools
python3Packages.setuptools-scm
python3Packages.wheel
];
propagatedBuildInputs = with python3Packages; [ iniparse ];
postInstall = ''
# this just creates the man page
make all
install -Dm444 -t $out/share/doc/${pname} README.md EXAMPLES
installManPage *.1
'';
checkPhase = ''
runHook preCheck
pushd tests >/dev/null
./test.sh
popd >/dev/null
runHook postCheck
'';
meta = {
description = "Utility for manipulating ini files";
homepage = "https://www.pixelbeat.org/programs/crudini/";
license = lib.licenses.gpl2Only;
maintainers = with lib.maintainers; [ peterhoeg ];
mainProgram = "crudini";
};
}