nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 98 lines 2.3 kB view raw
1{ 2 lib, 3 fetchFromGitHub, 4 wrapGAppsHook3, 5 gettext, 6 python3Packages, 7 adwaita-icon-theme, 8 gtk3, 9 glib, 10 gdk-pixbuf, 11 gsettings-desktop-schemas, 12 gobject-introspection, 13}: 14 15let 16 inherit (python3Packages) 17 buildPythonApplication 18 dbus-python 19 pygobject3 20 mpd2 21 setuptools 22 ; 23in 24buildPythonApplication rec { 25 pname = "sonata"; 26 version = "1.7.3"; 27 pyproject = true; 28 29 src = fetchFromGitHub { 30 owner = "multani"; 31 repo = "sonata"; 32 tag = "v${version}"; 33 hash = "sha256-eyB+DHcAg1nYjE415VjpPnqZC9embYRhnwXhN2ZVN0o="; 34 }; 35 36 nativeBuildInputs = [ 37 gettext 38 gobject-introspection 39 wrapGAppsHook3 40 ]; 41 42 buildInputs = [ 43 glib 44 adwaita-icon-theme 45 gsettings-desktop-schemas 46 gtk3 47 gdk-pixbuf 48 ]; 49 50 build-system = [ setuptools ]; 51 52 # The optional tagpy dependency (for editing metadata) is not yet 53 # included because it's difficult to build. 54 pythonPath = [ 55 dbus-python 56 mpd2 57 pygobject3 58 setuptools # pkg_resources is imported during runtime 59 ]; 60 61 postPatch = '' 62 # Remove "Local MPD" tab which is not suitable for NixOS. 63 sed -i '/localmpd/d' sonata/consts.py 64 ''; 65 66 meta = { 67 description = "Elegant client for the Music Player Daemon"; 68 mainProgram = "sonata"; 69 longDescription = '' 70 Sonata is an elegant client for the Music Player Daemon. 71 72 Written in Python and using the GTK 3 widget set, its features 73 include: 74 75 - Expanded and collapsed views 76 - Automatic remote and local album art 77 - Library browsing by folders, or by genre/artist/album 78 - User-configurable columns 79 - Automatic fetching of lyrics 80 - Playlist and stream support 81 - Support for editing song tags (not in NixOS version) 82 - Drag and drop to copy files 83 - Popup notification 84 - Library and playlist searching, filter as you type 85 - Audioscrobbler (last.fm) 1.2 support 86 - Multiple MPD profiles 87 - Keyboard friendly 88 - Support for multimedia keys 89 - Commandline control 90 - Available in 24 languages 91 ''; 92 homepage = "https://www.nongnu.org/sonata/"; 93 changelog = "https://github.com/multani/sonata/blob/${src.tag}/CHANGELOG"; 94 license = lib.licenses.gpl3Plus; 95 maintainers = [ ]; 96 platforms = lib.platforms.linux; 97 }; 98}