Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 19.09 62 lines 1.6 kB view raw
1{ stdenv, lib, buildPythonPackage, fetchFromGitHub, isPy3k 2, notmuch, urwid, urwidtrees, twisted, python_magic, configobj, mock, file, gpgme 3, service-identity 4, gnupg ? null, sphinx, awk ? null, procps ? null, future ? null 5, withManpage ? false }: 6 7 8buildPythonPackage rec { 9 pname = "alot"; 10 version = "0.8"; 11 outputs = [ "out" ] ++ lib.optional withManpage "man"; 12 13 disabled = !isPy3k; 14 15 src = fetchFromGitHub { 16 owner = "pazz"; 17 repo = "alot"; 18 rev = version; 19 sha256 = "1isn0p0i2a7dlbrdk5ib01xa1wgi6bi9ka4xl4vj8iw1q4i5fqv9"; 20 }; 21 22 nativeBuildInputs = lib.optional withManpage sphinx; 23 24 propagatedBuildInputs = [ 25 notmuch 26 urwid 27 urwidtrees 28 twisted 29 python_magic 30 configobj 31 service-identity 32 file 33 gpgme 34 ]; 35 36 # some twisted tests need the network (test_env_set... ) 37 doCheck = false; 38 postBuild = lib.optionalString withManpage "make -C docs man"; 39 40 checkInputs = [ awk future mock gnupg procps ]; 41 42 postInstall = lib.optionalString withManpage '' 43 mkdir -p $out/man 44 cp -r docs/build/man $out/man 45 '' 46 + '' 47 mkdir -p $out/share/{applications,alot} 48 cp -r extra/themes $out/share/alot 49 50 install -D extra/completion/alot-completion.zsh $out/share/zsh/site-functions/_alot 51 52 sed "s,/usr/bin,$out/bin,g" extra/alot.desktop > $out/share/applications/alot.desktop 53 ''; 54 55 meta = with stdenv.lib; { 56 homepage = https://github.com/pazz/alot; 57 description = "Terminal MUA using notmuch mail"; 58 license = licenses.gpl3; 59 platforms = platforms.linux; 60 maintainers = with maintainers; [ ]; 61 }; 62}