forked from mirrors/nixpkgs
ytui-music: init at 2.0.0-rc1
This commit is contained in:
parent
0a991e0394
commit
66733f9113
68
pkgs/by-name/yt/ytui-music/package.nix
Normal file
68
pkgs/by-name/yt/ytui-music/package.nix
Normal file
|
@ -0,0 +1,68 @@
|
|||
{ lib
|
||||
, rustPlatform
|
||||
, fetchFromGitHub
|
||||
, pkg-config
|
||||
, openssl
|
||||
, sqlite
|
||||
, stdenv
|
||||
, darwin
|
||||
, mpv
|
||||
, youtube-dl
|
||||
, makeBinaryWrapper
|
||||
}:
|
||||
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "ytui-music";
|
||||
version = "2.0.0-rc1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "sudipghimire533";
|
||||
repo = "ytui-music";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-f/23PVk4bpUCvcQ25iNI/UVXqiPBzPKWq6OohVF41p8=";
|
||||
};
|
||||
|
||||
cargoHash = "sha256-766Wev2/R/9LLlWWxOPl6y4CBRUU4hUrTDlVVuoJ8C8=";
|
||||
|
||||
checkFlags = [
|
||||
"--skip=tests::display_config_path"
|
||||
"--skip=tests::inspect_server_list"
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
pkg-config
|
||||
makeBinaryWrapper
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
openssl
|
||||
sqlite
|
||||
mpv
|
||||
] ++ lib.optionals stdenv.isDarwin [
|
||||
darwin.apple_sdk.frameworks.CoreFoundation
|
||||
darwin.apple_sdk.frameworks.Security
|
||||
];
|
||||
|
||||
postInstall = ''
|
||||
wrapProgram $out/bin/ytui_music \
|
||||
--prefix PATH : ${lib.makeBinPath [ youtube-dl ]}
|
||||
'';
|
||||
|
||||
doInstallCheck = true;
|
||||
|
||||
installCheckPhase = ''
|
||||
runHook preInstallCheck
|
||||
|
||||
$out/bin/ytui_music help
|
||||
|
||||
runHook postInstallCheck
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Youtube client in terminal for music";
|
||||
homepage = "https://github.com/sudipghimire533/ytui-music";
|
||||
license = licenses.gpl2Only;
|
||||
maintainers = with maintainers; [ kashw2 ];
|
||||
mainProgram = "ytui_music";
|
||||
};
|
||||
}
|
Loading…
Reference in a new issue