2023-02-02 18:25:31 +00:00
|
|
|
{ lib
|
2024-01-25 14:12:00 +00:00
|
|
|
, buildGoModule
|
2023-04-29 16:46:19 +00:00
|
|
|
, fetchFromGitHub
|
2023-02-02 18:25:31 +00:00
|
|
|
, pkg-config
|
|
|
|
, alsa-lib
|
|
|
|
, flac
|
2023-05-24 13:37:59 +00:00
|
|
|
, nix-update-script
|
2023-02-02 18:25:31 +00:00
|
|
|
}:
|
|
|
|
|
2024-01-25 14:12:00 +00:00
|
|
|
buildGoModule rec {
|
2023-02-02 18:25:31 +00:00
|
|
|
pname = "go-musicfox";
|
2024-02-29 20:09:43 +00:00
|
|
|
version = "4.3.1";
|
2023-02-02 18:25:31 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2023-05-24 13:37:59 +00:00
|
|
|
owner = "go-musicfox";
|
2023-02-02 18:25:31 +00:00
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2024-02-29 20:09:43 +00:00
|
|
|
hash = "sha256-QZHuQAOnthSm7Kb82i3NUWTnKk+9OMHV5vzOU72inX0=";
|
2023-02-02 18:25:31 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
deleteVendor = true;
|
|
|
|
|
2024-02-29 20:09:43 +00:00
|
|
|
vendorHash = "sha256-6DeoxpjVfykBI3fJAJpMZwJ4VTooIbxGpk5+SW198hU=";
|
2023-02-02 18:25:31 +00:00
|
|
|
|
|
|
|
subPackages = [ "cmd/musicfox.go" ];
|
|
|
|
|
|
|
|
ldflags = [
|
|
|
|
"-s"
|
|
|
|
"-w"
|
2023-10-19 13:55:26 +00:00
|
|
|
"-X github.com/go-musicfox/go-musicfox/internal/types.AppVersion=${version}"
|
2023-02-02 18:25:31 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
pkg-config
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
alsa-lib
|
|
|
|
flac
|
|
|
|
];
|
|
|
|
|
2023-05-24 13:37:59 +00:00
|
|
|
passthru.updateScript = nix-update-script { };
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Terminal netease cloud music client written in Go";
|
|
|
|
homepage = "https://github.com/anhoder/go-musicfox";
|
|
|
|
license = licenses.mit;
|
|
|
|
mainProgram = "musicfox";
|
2023-04-29 16:46:19 +00:00
|
|
|
maintainers = with maintainers; [ zendo Ruixi-rebirth aleksana ];
|
2023-02-02 18:25:31 +00:00
|
|
|
};
|
|
|
|
}
|