From 619db5d8f47a33b6ab851239cafedcc582ef8313 Mon Sep 17 00:00:00 2001 From: aleksana Date: Tue, 18 Jun 2024 21:46:55 +0800 Subject: [PATCH 1/5] gnome-feeds: move to pkgs/by-name --- .../feedreaders => by-name/gn}/gnome-feeds/listparser.nix | 0 .../default.nix => by-name/gn/gnome-feeds/package.nix} | 0 pkgs/top-level/all-packages.nix | 2 -- 3 files changed, 2 deletions(-) rename pkgs/{applications/networking/feedreaders => by-name/gn}/gnome-feeds/listparser.nix (100%) rename pkgs/{applications/networking/feedreaders/gnome-feeds/default.nix => by-name/gn/gnome-feeds/package.nix} (100%) diff --git a/pkgs/applications/networking/feedreaders/gnome-feeds/listparser.nix b/pkgs/by-name/gn/gnome-feeds/listparser.nix similarity index 100% rename from pkgs/applications/networking/feedreaders/gnome-feeds/listparser.nix rename to pkgs/by-name/gn/gnome-feeds/listparser.nix diff --git a/pkgs/applications/networking/feedreaders/gnome-feeds/default.nix b/pkgs/by-name/gn/gnome-feeds/package.nix similarity index 100% rename from pkgs/applications/networking/feedreaders/gnome-feeds/default.nix rename to pkgs/by-name/gn/gnome-feeds/package.nix diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 4e6d8abd82538bb..68959b916191050 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8347,8 +8347,6 @@ with pkgs; gnome-extension-manager = callPackage ../applications/misc/gnome-extension-manager { }; - gnome-feeds = callPackage ../applications/networking/feedreaders/gnome-feeds { }; - gnome-frog = callPackage ../applications/misc/gnome-frog { }; gnome-keysign = callPackage ../tools/security/gnome-keysign { }; From 7372a014001a5503aad95abbd4421f63b8fa11b2 Mon Sep 17 00:00:00 2001 From: aleksana Date: Tue, 18 Jun 2024 21:50:58 +0800 Subject: [PATCH 2/5] gnome-feeds: format with nixfmt-rfc-style --- pkgs/by-name/gn/gnome-feeds/listparser.nix | 11 +++---- pkgs/by-name/gn/gnome-feeds/package.nix | 37 +++++++++++----------- 2 files changed, 23 insertions(+), 25 deletions(-) diff --git a/pkgs/by-name/gn/gnome-feeds/listparser.nix b/pkgs/by-name/gn/gnome-feeds/listparser.nix index 7dd2f752598fa92..09e41d63e4c0a83 100644 --- a/pkgs/by-name/gn/gnome-feeds/listparser.nix +++ b/pkgs/by-name/gn/gnome-feeds/listparser.nix @@ -1,6 +1,7 @@ -{ lib -, python3 -, fetchPypi +{ + lib, + python3, + fetchPypi, }: python3.pkgs.buildPythonPackage rec { @@ -25,9 +26,7 @@ python3.pkgs.buildPythonPackage rec { description = "Parser for subscription lists"; homepage = "https://github.com/kurtmckee/listparser"; license = licenses.lgpl3Plus; - maintainers = [ - maintainers.pbogdan - ]; + maintainers = [ maintainers.pbogdan ]; platforms = platforms.linux; }; } diff --git a/pkgs/by-name/gn/gnome-feeds/package.nix b/pkgs/by-name/gn/gnome-feeds/package.nix index def8bfb515200f7..51200b7c091544b 100644 --- a/pkgs/by-name/gn/gnome-feeds/package.nix +++ b/pkgs/by-name/gn/gnome-feeds/package.nix @@ -1,22 +1,23 @@ -{ lib -, callPackage +{ + lib, + callPackage, -, fetchFromGitLab + fetchFromGitLab, -, appstream -, gobject-introspection -, meson -, ninja -, pkg-config -, wrapGAppsHook3 + appstream, + gobject-introspection, + meson, + ninja, + pkg-config, + wrapGAppsHook3, -, glib -, glib-networking -, gtk3 -, libhandy -, listparser ? callPackage ./listparser.nix { } -, webkitgtk -, python3 + glib, + glib-networking, + gtk3, + libhandy, + listparser ? callPackage ./listparser.nix { }, + webkitgtk, + python3, }: python3.pkgs.buildPythonApplication rec { @@ -81,9 +82,7 @@ python3.pkgs.buildPythonApplication rec { mainProgram = "gfeeds"; homepage = "https://gitlab.gnome.org/World/gfeeds"; license = licenses.gpl3Plus; - maintainers = [ - maintainers.pbogdan - ]; + maintainers = [ maintainers.pbogdan ]; platforms = platforms.linux; }; } From b918680e7b5fe2ceb097eaf08f07e2c4641e92b7 Mon Sep 17 00:00:00 2001 From: aleksana Date: Tue, 18 Jun 2024 22:27:32 +0800 Subject: [PATCH 3/5] syndication-domination: init at 1.0-unstable-2023-03-25 --- .../sy/syndication-domination/package.nix | 55 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 5 ++ 2 files changed, 60 insertions(+) create mode 100644 pkgs/by-name/sy/syndication-domination/package.nix diff --git a/pkgs/by-name/sy/syndication-domination/package.nix b/pkgs/by-name/sy/syndication-domination/package.nix new file mode 100644 index 000000000000000..10e325d8564253e --- /dev/null +++ b/pkgs/by-name/sy/syndication-domination/package.nix @@ -0,0 +1,55 @@ +{ + lib, + stdenv, + fetchFromGitLab, + meson, + ninja, + pkg-config, + pugixml, + fmt, + html-tidy, + enablePython? false, + python3Packages, +}: + +stdenv.mkDerivation { + pname = "syndication-domination"; + # author extraction feature needed by gnome-feeds + version = "1.0-unstable-2023-03-25"; + + src = fetchFromGitLab { + owner = "gabmus"; + repo = "syndication-domination"; + rev = "75920321062d682437f3fb0319dad227d8b18f6c"; + hash = "sha256-fOlE9CsNcmGkVBXaqYHxLDWB8voeRp46+dZYIJIwg7o="; + }; + + nativeBuildInputs = [ + meson + ninja + pkg-config + ]; + + buildInputs = [ + pugixml + fmt + html-tidy + ] ++ lib.optionals enablePython [ + python3Packages.python + python3Packages.pybind11 + ]; + + mesonFlags = [ + (lib.mesonBool "TO_JSON_BINARY" true) + (lib.mesonBool "PYTHON_BINDINGS" enablePython) + ]; + + meta = { + description = "RSS/Atom parser written in C++ with Python binding"; + homepage = "https://gitlab.com/gabmus/syndication-domination"; + license = lib.licenses.agpl3Only; + mainProgram = "SyndicationDomination"; + maintainers = with lib.maintainers; [ aleksana ]; + platforms = lib.platforms.all; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 483cb05e69962fd..5bb5b4fdf1e7b7c 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -14818,6 +14818,11 @@ self: super: with self; { syncer = callPackage ../development/python-modules/syncer { }; + syndication-domination = toPythonModule (pkgs.syndication-domination.override { + enablePython = true; + python3Packages = self; + }); + synergy = callPackage ../development/python-modules/synergy { }; synologydsm-api = callPackage ../development/python-modules/synologydsm-api { }; From 6c895ffbe9eb840f6e006ac7b34bce82598242fb Mon Sep 17 00:00:00 2001 From: aleksana Date: Tue, 18 Jun 2024 22:46:03 +0800 Subject: [PATCH 4/5] gnome-feeds: 0.16.2 -> 2.2.0 --- pkgs/by-name/gn/gnome-feeds/listparser.nix | 32 ----------- pkgs/by-name/gn/gnome-feeds/package.nix | 64 ++++++++++++---------- 2 files changed, 34 insertions(+), 62 deletions(-) delete mode 100644 pkgs/by-name/gn/gnome-feeds/listparser.nix diff --git a/pkgs/by-name/gn/gnome-feeds/listparser.nix b/pkgs/by-name/gn/gnome-feeds/listparser.nix deleted file mode 100644 index 09e41d63e4c0a83..000000000000000 --- a/pkgs/by-name/gn/gnome-feeds/listparser.nix +++ /dev/null @@ -1,32 +0,0 @@ -{ - lib, - python3, - fetchPypi, -}: - -python3.pkgs.buildPythonPackage rec { - pname = "listparser"; - version = "0.18"; - - src = fetchPypi { - inherit pname version; - sha256 = "0hdqs1mmayw1r8yla43hgb4d9y3zqs5483vgf8j9ygczkd2wrq2b"; - }; - - propagatedBuildInputs = with python3.pkgs; [ - requests - six - ]; - - checkPhase = '' - ${python3.interpreter} lptest.py - ''; - - meta = with lib; { - description = "Parser for subscription lists"; - homepage = "https://github.com/kurtmckee/listparser"; - license = licenses.lgpl3Plus; - maintainers = [ maintainers.pbogdan ]; - platforms = platforms.linux; - }; -} diff --git a/pkgs/by-name/gn/gnome-feeds/package.nix b/pkgs/by-name/gn/gnome-feeds/package.nix index 51200b7c091544b..0eb92170255d9ad 100644 --- a/pkgs/by-name/gn/gnome-feeds/package.nix +++ b/pkgs/by-name/gn/gnome-feeds/package.nix @@ -1,64 +1,72 @@ { lib, - callPackage, + python3, fetchFromGitLab, + fetchpatch, appstream, gobject-introspection, meson, ninja, pkg-config, - wrapGAppsHook3, + blueprint-compiler, + wrapGAppsHook4, - glib, glib-networking, - gtk3, - libhandy, - listparser ? callPackage ./listparser.nix { }, - webkitgtk, - python3, + libadwaita, + webkitgtk_6_0, }: python3.pkgs.buildPythonApplication rec { pname = "gnome-feeds"; - version = "0.16.2"; + version = "2.2.0"; + pyproject = false; src = fetchFromGitLab { domain = "gitlab.gnome.org"; owner = "World"; repo = "gfeeds"; rev = version; - sha256 = "sha256-66dwVR9owg050aHCHJek7jYnT+/yyCKo4AaUE0hCqBA="; + hash = "sha256-XKwRFjz4ocH01mj8KshLGmGxbm/uvDiyYRf65KL0UFw="; }; - format = "other"; + patches = [ + # both patches needed to built with newer blueprint-compiler + (fetchpatch { + name = "fix-for-blueprint-0.8.patch"; + url = "https://gitlab.gnome.org/World/gfeeds/-/commit/cfe860f44f685be302e2ad9f30b55bab08e078ce.patch"; + hash = "sha256-exkq9KykB60/X8u3+T1/sShrhGP8BvNkaBWPzm2mchc="; + }) + (fetchpatch { + name = "upgrade-blueprint-0.8-syntax.patch"; + url = "https://gitlab.gnome.org/World/gfeeds/-/commit/d099fda0c62e338080061683a154f711cc487b30.patch"; + hash = "sha256-M6QLRTj+CItk3XPDeexf3/+B1YHJoHsTjwdE6iw1xjM="; + }) + ]; nativeBuildInputs = [ appstream - glib # for glib-compile-schemas gobject-introspection meson ninja pkg-config - wrapGAppsHook3 + blueprint-compiler + wrapGAppsHook4 ]; buildInputs = [ - glib glib-networking - gtk3 - libhandy - webkitgtk + libadwaita + webkitgtk_6_0 ]; - propagatedBuildInputs = with python3.pkgs; [ + dependencies = with python3.pkgs; [ beautifulsoup4 + humanize python-dateutil - feedparser - html5lib - listparser - lxml + syndication-domination + python-magic pillow pygments pygobject3 @@ -73,16 +81,12 @@ python3.pkgs.buildPythonApplication rec { makeWrapperArgs+=("''${gappsWrapperArgs[@]}") ''; - passthru = { - inherit listparser; - }; - - meta = with lib; { + meta = { description = "RSS/Atom feed reader for GNOME"; mainProgram = "gfeeds"; homepage = "https://gitlab.gnome.org/World/gfeeds"; - license = licenses.gpl3Plus; - maintainers = [ maintainers.pbogdan ]; - platforms = platforms.linux; + license = lib.licenses.gpl3Plus; + maintainers = [ lib.maintainers.pbogdan ]; + platforms = lib.platforms.linux; }; } From 46653e00191badde8a1ebb39f31809be3fb22d13 Mon Sep 17 00:00:00 2001 From: aleksana Date: Tue, 18 Jun 2024 22:46:51 +0800 Subject: [PATCH 5/5] gnome-feeds: add aleksana as maintainer --- pkgs/by-name/gn/gnome-feeds/package.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkgs/by-name/gn/gnome-feeds/package.nix b/pkgs/by-name/gn/gnome-feeds/package.nix index 0eb92170255d9ad..e502a17bdbed1f4 100644 --- a/pkgs/by-name/gn/gnome-feeds/package.nix +++ b/pkgs/by-name/gn/gnome-feeds/package.nix @@ -86,7 +86,10 @@ python3.pkgs.buildPythonApplication rec { mainProgram = "gfeeds"; homepage = "https://gitlab.gnome.org/World/gfeeds"; license = lib.licenses.gpl3Plus; - maintainers = [ lib.maintainers.pbogdan ]; + maintainers = with lib.maintainers; [ + pbogdan + aleksana + ]; platforms = lib.platforms.linux; }; }