pytrainer: unpin python 3.10
[NixPkgs.git] / pkgs / servers / headphones / default.nix
blobfa33d16961fe279d4c3f691a243848ee2898c993
1 { lib, fetchFromGitHub, python3, makeWrapper }:
3 python3.pkgs.buildPythonApplication rec {
4   pname = "headphones";
5   version = "0.6.3";
6   format = "other";
8   src = fetchFromGitHub {
9     owner = "rembo10";
10     repo = "headphones";
11     rev = "v${version}";
12     sha256 = "195v0ylhqd49bqq3dpig5nh0kivmwgmn0977fknix9j14jpvmd3b";
13   };
15   dontBuild = true;
16   doCheck = false;
18   nativeBuildInputs = [ makeWrapper ];
20   installPhase = ''
21     runHook preInstall
23     mkdir -p $out/bin $out/opt/headphones
24     cp -R {data,headphones,lib,Headphones.py} $out/opt/headphones
26     echo v${version} > $out/opt/headphones/version.txt
28     makeWrapper $out/opt/headphones/Headphones.py $out/bin/headphones
30     runHook postInstall
31   '';
33   meta = with lib; {
34     description = "Automatic music downloader for SABnzbd";
35     license     = licenses.gpl3Plus;
36     homepage    = "https://github.com/rembo10/headphones";
37     maintainers = with lib.maintainers; [ rembo10 ];
38     mainProgram = "headphones";
39   };