2021-01-25 09:26:54 +01:00
|
|
|
{ lib, fetchFromGitHub, wrapGAppsHook, gettext
|
2020-08-30 21:57:11 +02:00
|
|
|
, python3Packages, gnome3, gtk3, glib, gdk-pixbuf, gsettings-desktop-schemas, gobject-introspection }:
|
2016-01-30 11:28:12 +01:00
|
|
|
|
2016-08-16 22:51:21 +02:00
|
|
|
let
|
2019-12-16 16:21:05 +01:00
|
|
|
inherit (python3Packages) buildPythonApplication isPy3k dbus-python pygobject3 mpd2 setuptools;
|
2016-08-16 22:51:21 +02:00
|
|
|
in buildPythonApplication rec {
|
2018-06-23 15:27:58 +02:00
|
|
|
pname = "sonata";
|
2020-12-26 01:14:33 +01:00
|
|
|
version = "1.7.0";
|
2016-01-30 11:28:12 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "multani";
|
|
|
|
repo = "sonata";
|
|
|
|
rev = "v${version}";
|
2020-12-26 01:14:33 +01:00
|
|
|
sha256 = "0rl8w7s2asff626clzfvyz987l2k4ml5dg417mqp9v8a962q0v2x";
|
2016-01-30 11:28:12 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
disabled = !isPy3k;
|
|
|
|
|
2020-08-30 21:57:11 +02:00
|
|
|
nativeBuildInputs = [
|
|
|
|
gettext
|
|
|
|
gobject-introspection
|
|
|
|
wrapGAppsHook
|
|
|
|
];
|
|
|
|
|
2016-01-30 11:28:12 +01:00
|
|
|
buildInputs = [
|
2020-08-30 21:57:11 +02:00
|
|
|
glib
|
2019-02-13 22:47:50 +01:00
|
|
|
gnome3.adwaita-icon-theme
|
2019-04-17 02:38:26 +02:00
|
|
|
gsettings-desktop-schemas
|
2020-08-30 21:57:11 +02:00
|
|
|
gtk3
|
|
|
|
gdk-pixbuf
|
|
|
|
];
|
|
|
|
|
|
|
|
# The optional tagpy dependency (for editing metadata) is not yet
|
|
|
|
# included because it's difficult to build.
|
|
|
|
pythonPath = [
|
|
|
|
dbus-python
|
|
|
|
mpd2
|
|
|
|
pygobject3
|
|
|
|
setuptools
|
2016-01-30 11:28:12 +01:00
|
|
|
];
|
|
|
|
|
2020-08-30 21:57:11 +02:00
|
|
|
# Otherwise the setup hook for gobject-introspection is not run:
|
2020-08-29 18:57:25 +02:00
|
|
|
# https://github.com/NixOS/nixpkgs/issues/56943
|
|
|
|
strictDeps = false;
|
|
|
|
|
2016-01-30 11:28:12 +01:00
|
|
|
postPatch = ''
|
|
|
|
# Remove "Local MPD" tab which is not suitable for NixOS.
|
|
|
|
sed -i '/localmpd/d' sonata/consts.py
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "An elegant client for the Music Player Daemon";
|
|
|
|
longDescription = ''
|
|
|
|
Sonata is an elegant client for the Music Player Daemon.
|
|
|
|
|
2019-09-04 00:49:40 +02:00
|
|
|
Written in Python and using the GTK 3 widget set, its features
|
2016-01-30 11:28:12 +01:00
|
|
|
include:
|
|
|
|
|
|
|
|
- Expanded and collapsed views
|
|
|
|
- Automatic remote and local album art
|
|
|
|
- Library browsing by folders, or by genre/artist/album
|
|
|
|
- User-configurable columns
|
|
|
|
- Automatic fetching of lyrics
|
|
|
|
- Playlist and stream support
|
|
|
|
- Support for editing song tags (not in NixOS version)
|
|
|
|
- Drag and drop to copy files
|
|
|
|
- Popup notification
|
|
|
|
- Library and playlist searching, filter as you type
|
|
|
|
- Audioscrobbler (last.fm) 1.2 support
|
|
|
|
- Multiple MPD profiles
|
|
|
|
- Keyboard friendly
|
|
|
|
- Support for multimedia keys
|
|
|
|
- Commandline control
|
|
|
|
- Available in 24 languages
|
|
|
|
'';
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "https://www.nongnu.org/sonata/";
|
2021-01-15 14:21:58 +01:00
|
|
|
license = lib.licenses.gpl3;
|
|
|
|
platforms = lib.platforms.linux;
|
|
|
|
maintainers = [ lib.maintainers.rvl ];
|
2016-01-30 11:28:12 +01:00
|
|
|
};
|
|
|
|
}
|