nixpkgs/pkgs/applications/audio/pyradio/default.nix
stuebinm ff1a94e523 treewide: add meta.mainProgram to packages with a single binary
The nixpkgs-unstable channel's programs.sqlite was used to identify
packages producing exactly one binary, and these automatically added
to their package definitions wherever possible.
2024-03-19 03:14:51 +01:00

47 lines
952 B
Nix

{ lib
, python3Packages
, fetchFromGitHub
, installShellFiles
}:
python3Packages.buildPythonApplication rec {
pname = "pyradio";
version = "0.9.2.25";
src = fetchFromGitHub {
owner = "coderholic";
repo = "pyradio";
rev = "refs/tags/${version}";
hash = "sha256-GkOp0iK84HDvVH8RmtmIKJ5EtQIECgZS5g8pmaIhUcc=";
};
nativeBuildInputs = [
installShellFiles
];
propagatedBuildInputs = with python3Packages; [
dnspython
netifaces
psutil
python-dateutil
requests
rich
];
checkPhase = ''
$out/bin/pyradio --help
'';
postInstall = ''
installManPage *.1
'';
meta = with lib; {
homepage = "http://www.coderholic.com/pyradio/";
description = "Curses based internet radio player";
mainProgram = "pyradio";
changelog = "https://github.com/coderholic/pyradio/releases/tag/${version}";
license = licenses.mit;
maintainers = with maintainers; [ contrun ];
};
}