From 2dff34b56b6d0c6c315306ca346f063df42cda3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Romildo=20Malaquias?= Date: Sat, 4 Apr 2020 22:53:24 -0300 Subject: [PATCH 1/6] xfce: add pos attribute in mkXfcederivation --- pkgs/desktops/xfce/mkXfceDerivation.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkgs/desktops/xfce/mkXfceDerivation.nix b/pkgs/desktops/xfce/mkXfceDerivation.nix index b7dc83225696..ed604a02824a 100644 --- a/pkgs/desktops/xfce/mkXfceDerivation.nix +++ b/pkgs/desktops/xfce/mkXfceDerivation.nix @@ -27,6 +27,8 @@ let enableParallelBuilding = true; outputs = [ "out" "dev" ]; + pos = builtins.unsafeGetAttrPos "pname" args; + meta = with stdenv.lib; { homepage = "https://git.xfce.org/${category}/${pname}/about"; license = licenses.gpl2; # some libraries are under LGPLv2+ From a772bc6eaefbcf2fa387105703c3c6b763c3695c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Romildo=20Malaquias?= Date: Mon, 6 Apr 2020 11:23:21 -0300 Subject: [PATCH 2/6] xfce.orage: the git repository has been archived (unmaintained) --- pkgs/desktops/xfce/applications/orage/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/desktops/xfce/applications/orage/default.nix b/pkgs/desktops/xfce/applications/orage/default.nix index ea025fbb33c6..08b78ec40067 100644 --- a/pkgs/desktops/xfce/applications/orage/default.nix +++ b/pkgs/desktops/xfce/applications/orage/default.nix @@ -8,7 +8,7 @@ let in mkXfceDerivation { - category = "apps"; + category = "archive"; pname = "orage"; version = "4.12.1"; From 827a6619eb7732b9b9e823fd8f120d2c78394f33 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Romildo=20Malaquias?= Date: Mon, 13 Apr 2020 17:57:30 -0300 Subject: [PATCH 3/6] common-updater-scripts: add scripts to help update packages - updateScript: A nix expression that can be used in passThrough to update a package - list-git-tags: A shell script to list available tags in a git repository - list-archive-two-level-versions: A shell script to list available versions in a web site in two levels: there is a page listing the available major.minor versions, and for each of them there is another page listings the patch level versions major.minor.patch. It is suitable for Xfce packages for instance. How the updater works: 1. collect the available versions from the source repository (using a script given as argument) 2. print the collected versions (for debugging) 3. (optionally) apply some transformation to the collected versions to make them compatible with the versions used in nixpkgs (for instance, tags in the Xfce git repository may be prefixed with the package name, and the prefix need to be removed) 4. sort the available versions in decreasing order 5. choose the first version that pass validation: - check if the version may be a development version - if the version IS unstable, skip it and give a warning about skipping a development version (for debugging) - if the version COULD BE unstable, take it and give a warning about taking a potential development version (for debugging) - if the version IS stable, take it 6. update the package version and checksum in its nix expression 7. print the git commands for adding the modified files and for committing the changes --- pkgs/common-updater/scripts.nix | 4 +- .../scripts/list-archive-two-level-versions | 35 +++++++ pkgs/common-updater/scripts/list-git-tags | 32 ++++++ pkgs/common-updater/update-script.nix | 98 +++++++++++++++++++ 4 files changed, 167 insertions(+), 2 deletions(-) create mode 100755 pkgs/common-updater/scripts/list-archive-two-level-versions create mode 100755 pkgs/common-updater/scripts/list-git-tags create mode 100644 pkgs/common-updater/update-script.nix diff --git a/pkgs/common-updater/scripts.nix b/pkgs/common-updater/scripts.nix index ec897914b6bd..655924e5f28a 100644 --- a/pkgs/common-updater/scripts.nix +++ b/pkgs/common-updater/scripts.nix @@ -1,4 +1,4 @@ -{ stdenv, makeWrapper, coreutils, gnused, gnugrep, diffutils, nix }: +{ stdenv, makeWrapper, coreutils, gnused, gnugrep, diffutils, nix, git }: stdenv.mkDerivation { name = "common-updater-scripts"; @@ -12,7 +12,7 @@ stdenv.mkDerivation { cp ${./scripts}/* $out/bin for f in $out/bin/*; do - wrapProgram $f --prefix PATH : ${stdenv.lib.makeBinPath [ coreutils gnused gnugrep nix diffutils ]} + wrapProgram $f --prefix PATH : ${stdenv.lib.makeBinPath [ coreutils gnused gnugrep nix diffutils git ]} done ''; } diff --git a/pkgs/common-updater/scripts/list-archive-two-level-versions b/pkgs/common-updater/scripts/list-archive-two-level-versions new file mode 100755 index 000000000000..e46652820ad2 --- /dev/null +++ b/pkgs/common-updater/scripts/list-archive-two-level-versions @@ -0,0 +1,35 @@ +#! /bin/sh + +# lists all available versions listed for a package in a site (http) + +scriptName=list-archive-two-level-versions # do not use the .wrapped name + +usage() { + echo "Usage: $scriptName [ []]" +} + +archive="$1" # archive url +pname="$2" # package name +file="$3" # file for writing debugging information + +if [ -z "$archive" ]; then + echo "$scriptName: Missing archive url" + usage + exit 1 +fi + +# print a debugging message +if [ -n "$file" ]; then + echo "# Listing versions for $pname at $archive" >> $file +fi + +# list all major-minor versions from archive +tags1=$(curl -sS "$archive/") +tags1=$(echo "$tags1" | sed -rne 's,^.*,\1,p') + +# print available versions +for tag in $tags1; do + tags2=$(curl -sS "$archive/$tag/") + tags2=$(echo "$tags2" | sed -rne "s,^.*,\\1,p") + echo "$tags2" +done diff --git a/pkgs/common-updater/scripts/list-git-tags b/pkgs/common-updater/scripts/list-git-tags new file mode 100755 index 000000000000..ff09671c7cb0 --- /dev/null +++ b/pkgs/common-updater/scripts/list-git-tags @@ -0,0 +1,32 @@ +#! /bin/sh -x + +# lists all available tags from a git repository + +scriptName=list-git-tags # do not use the .wrapped name + +usage() { + echo "Usage: $scriptName [ []]" +} + +repo="$1" # git repository url +pname="$2" # package name +file="$3" # file for writing debugging information + +if [ -z "$repo" ]; then + echo "$scriptName: Missing git repository url" + usage + exit 1 +fi + +# print a debugging message +if [ -n "$file" ]; then + echo "# Listing tags for $pname at $repo" >> $file +fi + +# list all tags from the remote repository +tags=$(git ls-remote --tags --refs "$repo") + +# keep only the version part of the tag +tags=$(echo "$tags" | cut --delimiter=/ --field=3) + +echo "$tags" diff --git a/pkgs/common-updater/update-script.nix b/pkgs/common-updater/update-script.nix new file mode 100644 index 000000000000..8e8153d9a332 --- /dev/null +++ b/pkgs/common-updater/update-script.nix @@ -0,0 +1,98 @@ +{ stdenv, writeScript, coreutils, gnugrep, gnused, common-updater-scripts, nix }: + +{ pname +, version +, attrPath ? pname +, versionLister +, rev-prefix ? "" +, odd-unstable ? true +, patchlevel-unstable ? true +}: + +let + # where to print git commands and debugging messages + fileForGitCommands = "update-git-commits.txt"; + + # shell script to update package + updateScript = writeScript "update-script.sh" '' + #! ${stdenv.shell} + set -o errexit + set -x + + pname="$1" + version="$2" + attr_path="$3" + version_lister="$4" + rev_prefix="$5" + odd_unstable="$6" + patchlevel_unstable="$7" + + # print header + echo "# $pname-$version" >> ${fileForGitCommands} + + function version_is_unstable() { + local tag="$1" + local enforce="$2" + if [ -n "$odd_unstable" -o -n "$enforce" ]; then + local minor=$(echo "$tag" | ${gnused}/bin/sed -rne 's,^[0-9]+\.([0-9]+).*,\1,p') + if [ $((minor % 2)) -eq 1 ]; then + return 0 + fi + fi + if [ -n "$patchlevel_unstable" -o -n "$enforce" ]; then + local patchlevel=$(echo "$tag" | ${gnused}/bin/sed -rne 's,^[0-9]+\.[0-9]+\.([0-9]+).*$,\1,p') + if ((patchlevel >= 90)); then + return 0 + fi + fi + return 1 + } + + tags=$($version_lister $pname ${fileForGitCommands}) || exit 1 + + # print available tags + for tag in $tags; do + echo "# found $pname version: $tag" >> ${fileForGitCommands} + done + + # cut any revision prefix not used in the NixOS package version + if [ -n "$rev_prefix" ]; then + tags=$(echo "$tags" | ${gnugrep}/bin/grep "^$rev_prefix") + tags=$(echo "$tags" | ${gnused}/bin/sed -e "s,^$rev_prefix,,") + fi + tags=$(echo "$tags" | ${gnugrep}/bin/grep "^[0-9]") + + # sort the tags in decreasing order + tags=$(echo "$tags" | ${coreutils}/bin/sort --reverse --version-sort) + + # find the newest tag + # do not consider development versions + for latest_tag in $tags; do + if version_is_unstable "$latest_tag"; then + echo "# skip development version: $pname-$latest_tag" >> ${fileForGitCommands} + latest_tag= + else + if version_is_unstable "$latest_tag" "enforce"; then + echo "# use potential development version: $pname-$latest_tag" >> ${fileForGitCommands} + fi + break + fi + done + + if [ -n "$latest_tag" ]; then + # print commands to commit the changes + if [ "$version" != "$latest_tag" ]; then + pfile=$(EDITOR=echo ${nix}/bin/nix edit -f. "$attr_path") + echo " git add $pfile " >> ${fileForGitCommands} + echo " git commit -m '$attr_path: $version -> $latest_tag'" >> ${fileForGitCommands} + fi + + # update the nix expression + ${common-updater-scripts}/bin/update-source-version "$attr_path" "$latest_tag" + fi + + echo "" >> ${fileForGitCommands} + ''; + +in +[ updateScript pname version attrPath versionLister rev-prefix odd-unstable patchlevel-unstable ] From 8162d76b18e17552f885ab01d9b9302707fd70c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Romildo=20Malaquias?= Date: Mon, 13 Apr 2020 18:09:24 -0300 Subject: [PATCH 4/6] xfce: tailor general update scripts to the xfce packages --- pkgs/desktops/xfce/default.nix | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/pkgs/desktops/xfce/default.nix b/pkgs/desktops/xfce/default.nix index 9f49299c03a8..e90eaa47e828 100644 --- a/pkgs/desktops/xfce/default.nix +++ b/pkgs/desktops/xfce/default.nix @@ -3,6 +3,14 @@ lib.makeScope pkgs.newScope (self: with self; { #### NixOS support + updateScript = callPackage ../../common-updater/update-script.nix { }; + + gitLister = url: + "${pkgs.common-updater-scripts}/bin/list-git-tags ${url}"; + + archiveLister = category: name: + "${pkgs.common-updater-scripts}/bin/list-archive-two-level-versions https://archive.xfce.org/src/${category}/${name}"; + mkXfceDerivation = callPackage ./mkXfceDerivation.nix { }; automakeAddFlags = pkgs.makeSetupHook { } ./automakeAddFlags.sh; From 06ba312152e99b9254a0950a97667b6c0ad2996e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Romildo=20Malaquias?= Date: Mon, 13 Apr 2020 18:12:16 -0300 Subject: [PATCH 5/6] xfce: add update scripts to xfce packages --- .../xfce/applications/gigolo/default.nix | 1 + .../xfce4-screenshooter/default.nix | 1 + .../applications/xfce4-volumed/default.nix | 18 +++++++---- .../xfce/applications/xfdashboard/default.nix | 3 +- pkgs/desktops/xfce/art/xfce4-icon-theme.nix | 26 ++++++++++------ pkgs/desktops/xfce/art/xfwm4-themes.nix | 20 +++++++++---- .../xfce/core/thunar-volman/default.nix | 2 ++ pkgs/desktops/xfce/mkXfceDerivation.nix | 21 +++++++++++-- .../xfce4-battery-plugin/default.nix | 5 ++-- .../xfce4-clipman-plugin/default.nix | 3 +- .../panel-plugins/xfce4-cpugraph-plugin.nix | 25 ++++++++++------ .../xfce4-datetime-plugin/default.nix | 5 ++-- .../xfce/panel-plugins/xfce4-dict-plugin.nix | 25 ++++++++++------ .../panel-plugins/xfce4-dockbarx-plugin.nix | 3 +- .../xfce/panel-plugins/xfce4-embed-plugin.nix | 22 +++++++++----- .../xfce/panel-plugins/xfce4-eyes-plugin.nix | 25 ++++++++++------ .../panel-plugins/xfce4-fsguard-plugin.nix | 25 ++++++++++------ .../panel-plugins/xfce4-genmon-plugin.nix | 25 ++++++++++------ .../xfce4-hardware-monitor-plugin.nix | 10 +++---- .../panel-plugins/xfce4-mailwatch-plugin.nix | 25 ++++++++++------ .../xfce/panel-plugins/xfce4-mpc-plugin.nix | 25 ++++++++++------ .../xfce4-netload-plugin/default.nix | 4 +-- .../xfce/panel-plugins/xfce4-notes-plugin.nix | 25 ++++++++++------ .../panel-plugins/xfce4-sensors-plugin.nix | 26 ++++++++++------ .../panel-plugins/xfce4-systemload-plugin.nix | 25 ++++++++++------ .../xfce/panel-plugins/xfce4-timer-plugin.nix | 25 ++++++++++------ .../default.nix | 6 ++++ .../xfce4-verve-plugin/default.nix | 4 +-- .../panel-plugins/xfce4-weather-plugin.nix | 30 ++++++++++++------- .../xfce4-whiskermenu-plugin/default.nix | 4 +-- .../panel-plugins/xfce4-windowck-plugin.nix | 16 ++++++---- .../xfce4-xkb-plugin/default.nix | 4 +-- .../xfce/thunar-plugins/archive/default.nix | 3 +- .../xfce/thunar-plugins/dropbox/default.nix | 7 +++++ 34 files changed, 324 insertions(+), 170 deletions(-) diff --git a/pkgs/desktops/xfce/applications/gigolo/default.nix b/pkgs/desktops/xfce/applications/gigolo/default.nix index 32486aab981f..7b643bd0dc88 100644 --- a/pkgs/desktops/xfce/applications/gigolo/default.nix +++ b/pkgs/desktops/xfce/applications/gigolo/default.nix @@ -4,6 +4,7 @@ mkXfceDerivation { category = "apps"; pname = "gigolo"; version = "0.5.0"; + odd-unstable = false; sha256 = "1lqsxb0d5i8p9vbzx8s4p3rga7va5h1q146xgmsa41j5v40wrlw6"; diff --git a/pkgs/desktops/xfce/applications/xfce4-screenshooter/default.nix b/pkgs/desktops/xfce/applications/xfce4-screenshooter/default.nix index 012486baac9b..1db6fb016a15 100644 --- a/pkgs/desktops/xfce/applications/xfce4-screenshooter/default.nix +++ b/pkgs/desktops/xfce/applications/xfce4-screenshooter/default.nix @@ -4,6 +4,7 @@ mkXfceDerivation { category = "apps"; pname = "xfce4-screenshooter"; version = "1.9.5"; + odd-unstable = false; sha256 = "1h14sywvk9l06p3z1cpb79911j8w2wqbk03ldknjkia2rfymjk06"; diff --git a/pkgs/desktops/xfce/applications/xfce4-volumed/default.nix b/pkgs/desktops/xfce/applications/xfce4-volumed/default.nix index 76e89a592b48..aec898161ffb 100644 --- a/pkgs/desktops/xfce/applications/xfce4-volumed/default.nix +++ b/pkgs/desktops/xfce/applications/xfce4-volumed/default.nix @@ -1,9 +1,11 @@ { stdenv, fetchurl, pkgconfig, makeWrapper , gstreamer, gtk2, gst-plugins-base, libnotify -, keybinder, xfconf +, keybinder, xfconf, xfce }: let + category = "apps"; + # The usual Gstreamer plugins package has a zillion dependencies # that we don't need for a simple mixer, so build a minimal package. gst_plugins_minimal = gst-plugins-base.override { @@ -13,15 +15,13 @@ let in stdenv.mkDerivation rec { - p_name = "xfce4-volumed"; - ver_maj = "0.1"; - ver_min = "13"; + pname = "xfce4-volumed"; + version = "0.1.13"; src = fetchurl { - url = "mirror://xfce/src/apps/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "1aa0a1sbf9yzi7bc78kw044m0xzg1li3y4w9kf20wqv5kfjs7v2c"; }; - name = "${p_name}-${ver_maj}.${ver_min}"; buildInputs = [ gstreamer gst_plugins_minimal gtk2 @@ -36,6 +36,12 @@ stdenv.mkDerivation rec { --prefix GST_PLUGIN_SYSTEM_PATH : "$GST_PLUGIN_SYSTEM_PATH" ''; + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; + meta = with stdenv.lib; { homepage = "https://www.xfce.org/projects/xfce4-volumed"; # referenced but inactive description = "A volume keys control daemon for the Xfce desktop environment"; diff --git a/pkgs/desktops/xfce/applications/xfdashboard/default.nix b/pkgs/desktops/xfce/applications/xfdashboard/default.nix index a17c29f6723e..f3db9c2446b8 100644 --- a/pkgs/desktops/xfce/applications/xfdashboard/default.nix +++ b/pkgs/desktops/xfce/applications/xfdashboard/default.nix @@ -18,7 +18,8 @@ mkXfceDerivation { category = "apps"; pname = "xfdashboard"; version = "0.7.5"; - rev = "0.7.5"; + rev-prefix = ""; + odd-unstable = false; sha256 = "0d0kg90h3li41bs75z3xldljsglkz220pba39c54qznnzb8v8a2i"; diff --git a/pkgs/desktops/xfce/art/xfce4-icon-theme.nix b/pkgs/desktops/xfce/art/xfce4-icon-theme.nix index 4f35dff42ff3..089b7cc27f87 100644 --- a/pkgs/desktops/xfce/art/xfce4-icon-theme.nix +++ b/pkgs/desktops/xfce/art/xfce4-icon-theme.nix @@ -1,23 +1,31 @@ -{ stdenv, fetchurl, pkgconfig, intltool, gtk2 }: +{ stdenv, fetchurl, pkgconfig, intltool, gtk2, xfce }: + +let + category = "art"; +in stdenv.mkDerivation rec { - p_name = "xfce4-icon-theme"; - ver_maj = "4.4"; - ver_min = "3"; + pname = "xfce4-icon-theme"; + version = "4.4.3"; src = fetchurl { - url = "mirror://xfce/src/art/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "1yk6rx3zr9grm4jwpjvqdkl13pisy7qn1wm5cqzmd2kbsn96cy6l"; }; - name = "${p_name}-${ver_maj}.${ver_min}"; nativeBuildInputs = [ pkgconfig ]; buildInputs = [ intltool gtk2 ]; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; - meta = { + meta = with stdenv.lib; { homepage = "https://www.xfce.org/"; description = "Icons for Xfce"; - platforms = stdenv.lib.platforms.linux; - maintainers = [ stdenv.lib.maintainers.eelco ]; + platforms = platforms.linux; + maintainers = [ maintainers.eelco ]; }; } diff --git a/pkgs/desktops/xfce/art/xfwm4-themes.nix b/pkgs/desktops/xfce/art/xfwm4-themes.nix index 1c40b7ec29b1..db0a1779a41b 100644 --- a/pkgs/desktops/xfce/art/xfwm4-themes.nix +++ b/pkgs/desktops/xfce/art/xfwm4-themes.nix @@ -1,15 +1,23 @@ -{ stdenv, fetchurl }: +{ stdenv, fetchurl, xfce }: + +let + category = "art"; +in stdenv.mkDerivation rec { - p_name = "xfwm4-themes"; - ver_maj = "4.10"; - ver_min = "0"; + pname = "xfwm4-themes"; + version = "4.10.0"; src = fetchurl { - url = "mirror://xfce/src/art/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "0xfmdykav4rf6gdxbd6fhmrfrvbdc1yjihz7r7lba0wp1vqda51j"; }; - name = "${p_name}-${ver_maj}.${ver_min}"; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; meta = with stdenv.lib; { homepage = "https://www.xfce.org/"; diff --git a/pkgs/desktops/xfce/core/thunar-volman/default.nix b/pkgs/desktops/xfce/core/thunar-volman/default.nix index fc6db0fcce4f..ecc26ccb8fea 100644 --- a/pkgs/desktops/xfce/core/thunar-volman/default.nix +++ b/pkgs/desktops/xfce/core/thunar-volman/default.nix @@ -9,6 +9,8 @@ mkXfceDerivation { sha256 = "1qrlpn0q5g9psd41l6y80r3bvbg8jaic92m6r400zzwcvivf95z0"; + odd-unstable = false; + meta = { description = "Thunar extension for automatic management of removable drives and media"; }; diff --git a/pkgs/desktops/xfce/mkXfceDerivation.nix b/pkgs/desktops/xfce/mkXfceDerivation.nix index ed604a02824a..4c6edf99b611 100644 --- a/pkgs/desktops/xfce/mkXfceDerivation.nix +++ b/pkgs/desktops/xfce/mkXfceDerivation.nix @@ -1,6 +1,16 @@ -{ stdenv, fetchgit, pkgconfig, xfce4-dev-tools, hicolor-icon-theme, wrapGAppsHook }: +{ stdenv, fetchgit, pkgconfig, xfce4-dev-tools, hicolor-icon-theme, xfce, wrapGAppsHook }: -{ category, pname, version, rev ? "${pname}-${version}", sha256, ... } @ args: +{ category +, pname +, version +, attrPath ? "xfce.${pname}" +, rev-prefix ? "${pname}-" +, rev ? "${rev-prefix}${version}" +, sha256 +, odd-unstable ? true +, patchlevel-unstable ? true +, ... +} @ args: let inherit (builtins) filter getAttr head isList; @@ -12,7 +22,7 @@ let concatAttrLists = attrsets: zipAttrsWithNames (filterAttrNames isList (head attrsets)) (_: concatLists) attrsets; - template = { + template = rec { name = "${pname}-${version}"; nativeBuildInputs = [ pkgconfig xfce4-dev-tools wrapGAppsHook ]; @@ -29,6 +39,11 @@ let pos = builtins.unsafeGetAttrPos "pname" args; + passthru.updateScript = xfce.updateScript { + inherit pname version attrPath rev-prefix odd-unstable patchlevel-unstable; + versionLister = xfce.gitLister src.url; + }; + meta = with stdenv.lib; { homepage = "https://git.xfce.org/${category}/${pname}/about"; license = licenses.gpl2; # some libraries are under LGPLv2+ diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-battery-plugin/default.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-battery-plugin/default.nix index 3966e256b160..0120cea0886f 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-battery-plugin/default.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-battery-plugin/default.nix @@ -1,10 +1,11 @@ { mkXfceDerivation, gtk3, libxfce4ui, libxfce4util, xfce4-panel, xfconf }: -mkXfceDerivation rec { +mkXfceDerivation { category = "panel-plugins"; pname = "xfce4-battery-plugin"; version = "1.1.2"; - rev = version; + rev-prefix = ""; + odd-unstable = false; sha256 = "0329miiclc8da6j0sz495p99hyrf9fjhvpmdl0556fphybz5agc0"; buildInputs = [ gtk3 libxfce4ui libxfce4util xfce4-panel xfconf ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-clipman-plugin/default.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-clipman-plugin/default.nix index bd1a3b5e5e35..f814850561a6 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-clipman-plugin/default.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-clipman-plugin/default.nix @@ -1,10 +1,9 @@ { mkXfceDerivation, gtk3, libXtst, libxfce4ui, libxfce4util, xfce4-panel, xfconf, exo }: -mkXfceDerivation rec { +mkXfceDerivation { category = "panel-plugins"; pname = "xfce4-clipman-plugin"; version = "1.4.3"; - rev = version; sha256 = "1xk79xh1zk0x4r1z9m1dakp79pip0zh3naviybvl1dnpwwfc03gq"; buildInputs = [ exo gtk3 libXtst libxfce4ui libxfce4util xfce4-panel xfconf ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-cpugraph-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-cpugraph-plugin.nix index 321e4792e4bc..22a019e56bc6 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-cpugraph-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-cpugraph-plugin.nix @@ -1,22 +1,29 @@ -{ stdenv, fetchurl, pkgconfig, intltool, glib, exo, libXtst, xorgproto, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2, hicolor-icon-theme }: +{ stdenv, fetchurl, pkgconfig, intltool, glib, exo, libXtst, xorgproto, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2, hicolor-icon-theme, xfce }: + +let + category = "panel-plugins"; +in -with stdenv.lib; stdenv.mkDerivation rec { - p_name = "xfce4-cpugraph-plugin"; - ver_maj = "1.0"; - ver_min = "5"; + pname = "xfce4-cpugraph-plugin"; + version = "1.0.5"; src = fetchurl { - url = "mirror://xfce/src/panel-plugins/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "1izl53q95m5xm2fiq7385vb1i9nwgjizxkmgpgh33zdckb40xnl5"; }; - name = "${p_name}-${ver_maj}.${ver_min}"; nativeBuildInputs = [ pkgconfig ]; buildInputs = [ intltool glib exo libXtst xorgproto libxfce4util libxfce4ui xfce4-panel xfconf gtk2 hicolor-icon-theme ]; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; - meta = { - homepage = "https://goodies.xfce.org/projects/panel-plugins/${p_name}"; + meta = with stdenv.lib; { + homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "CPU graph show for Xfce panel"; platforms = platforms.linux; maintainers = [ maintainers.AndersonTorres ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-datetime-plugin/default.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-datetime-plugin/default.nix index 3cfb010b12da..15f528fd5fc7 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-datetime-plugin/default.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-datetime-plugin/default.nix @@ -7,13 +7,12 @@ , gettext }: -mkXfceDerivation rec { +mkXfceDerivation { category = "panel-plugins"; pname = "xfce4-datetime-plugin"; version = "0.8.0"; - rev = "datetime-${version}"; - + rev-prefix = "datetime-"; sha256 = "12drh7y70d70r93lpv43fkj5cbyl0vciz4a41nxrknrfbhxrvyah"; nativeBuildInputs = [ diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-dict-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-dict-plugin.nix index d5982ea3c12a..ae6141bd6627 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-dict-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-dict-plugin.nix @@ -1,22 +1,29 @@ -{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2}: +{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2, xfce }: + +let + category = "panel-plugins"; +in -with stdenv.lib; stdenv.mkDerivation rec { - p_name = "xfce4-dict-plugin"; - ver_maj = "0.3"; - ver_min = "0"; + pname = "xfce4-dict-plugin"; + version = "0.3.0"; src = fetchurl { - url = "mirror://xfce/src/panel-plugins/${p_name}/${ver_maj}/${name}.tar.gz"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "1x0imfnsdfq7fbhka8bc0yjjspkcljc1jafhrwzb08qi9bk2wbar"; }; - name = "${p_name}-${ver_maj}.${ver_min}"; nativeBuildInputs = [ pkgconfig ]; buildInputs = [ intltool libxfce4util libxfce4ui xfce4-panel xfconf gtk2 ]; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; - meta = { - homepage = "https://goodies.xfce.org/projects/panel-plugins/${p_name}"; + meta =with stdenv.lib; { + homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "Dictionary plugin for Xfce panel"; platforms = platforms.linux; maintainers = [ maintainers.AndersonTorres ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-dockbarx-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-dockbarx-plugin.nix index db74da2939de..673b0a24fb61 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-dockbarx-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-dockbarx-plugin.nix @@ -2,9 +2,10 @@ , dockbarx, gtk2, xfce, pythonPackages, wafHook }: stdenv.mkDerivation rec { + pname = "xfce4-dockbarx-plugin"; + version = "${ver}-${rev}"; ver = "0.5"; rev = "a2dcb66"; - name = "xfce4-dockbarx-plugin-${ver}-${rev}"; src = fetchFromGitHub { owner = "TiZ-EX1"; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-embed-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-embed-plugin.nix index 94c26f9e1b2b..3cd847146635 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-embed-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-embed-plugin.nix @@ -1,22 +1,30 @@ -{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2 }: +{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2, xfce }: + +let + category = "panel-plugins"; +in with stdenv.lib; stdenv.mkDerivation rec { - p_name = "xfce4-embed-plugin"; - ver_maj = "1.6"; - ver_min = "0"; + pname = "xfce4-embed-plugin"; + version = "1.6.0"; src = fetchurl { - url = "mirror://xfce/src/panel-plugins/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "0a72kqsjjh45swimqlpyrahdnplp0383v0i4phr4n6g8c1ixyry7"; }; - name = "${p_name}-${ver_maj}.${ver_min}"; nativeBuildInputs = [ pkgconfig ]; buildInputs = [ intltool libxfce4util libxfce4ui xfce4-panel xfconf gtk2 ]; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; meta = { - homepage = "https://goodies.xfce.org/projects/panel-plugins/${p_name}"; + homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "Embed arbitrary app windows on Xfce panel"; platforms = platforms.linux; maintainers = [ maintainers.AndersonTorres ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-eyes-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-eyes-plugin.nix index 1932a9e9968e..687bcf59859e 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-eyes-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-eyes-plugin.nix @@ -1,22 +1,29 @@ -{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2}: +{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2, xfce }: + +let + category = "panel-plugins"; +in -with stdenv.lib; stdenv.mkDerivation rec { - p_name = "xfce4-eyes-plugin"; - ver_maj = "4.4"; - ver_min = "4"; + pname = "xfce4-eyes-plugin"; + version = "4.4.4"; src = fetchurl { - url = "mirror://xfce/src/panel-plugins/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "1jh02hylvsvfpxrx0bq6fzgy6vnxf9qakgpbfvr63lfkd1dyh314"; }; - name = "${p_name}-${ver_maj}.${ver_min}"; nativeBuildInputs = [ pkgconfig ]; buildInputs = [ intltool libxfce4util libxfce4ui xfce4-panel xfconf gtk2 ]; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; - meta = { - homepage = "https://goodies.xfce.org/projects/panel-plugins/${p_name}"; + meta = with stdenv.lib; { + homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "Eyes following you!"; platforms = platforms.linux; maintainers = [ maintainers.AndersonTorres ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-fsguard-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-fsguard-plugin.nix index 54bb4817d7e2..adab2f033ac2 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-fsguard-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-fsguard-plugin.nix @@ -1,22 +1,29 @@ -{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2}: +{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2, xfce }: + +let + category = "panel-plugins"; +in -with stdenv.lib; stdenv.mkDerivation rec { - p_name = "xfce4-fsguard-plugin"; - ver_maj = "1.0"; - ver_min = "2"; + pname = "xfce4-fsguard-plugin"; + version = "1.0.2"; src = fetchurl { - url = "mirror://xfce/src/panel-plugins/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "1bj021h4q68bc03f32pkyqy4gfd1sz6s21nxdg7j6gdfhs9xbj52"; }; - name = "${p_name}-${ver_maj}.${ver_min}"; nativeBuildInputs = [ pkgconfig ]; buildInputs = [ intltool libxfce4util libxfce4ui xfce4-panel xfconf gtk2 ]; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; - meta = { - homepage = "https://goodies.xfce.org/projects/panel-plugins/${p_name}"; + meta = with stdenv.lib; { + homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "Filesystem monitor"; platforms = platforms.linux; maintainers = [ maintainers.AndersonTorres ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-genmon-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-genmon-plugin.nix index dd9827dcc5a9..65dc61a4b393 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-genmon-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-genmon-plugin.nix @@ -1,22 +1,29 @@ -{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2}: +{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2, xfce }: + +let + category = "panel-plugins"; +in -with stdenv.lib; stdenv.mkDerivation rec { - p_name = "xfce4-genmon-plugin"; - ver_maj = "3.4"; - ver_min = "0"; + pname = "xfce4-genmon-plugin"; + version = "3.4.0"; src = fetchurl { - url = "mirror://xfce/src/panel-plugins/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "11q3g6lmgz3d5lyh6614mxkd9cblfdyf9jgki7f26mn895xk79dh"; }; - name = "${p_name}-${ver_maj}.${ver_min}"; nativeBuildInputs = [ pkgconfig ]; buildInputs = [ intltool libxfce4util libxfce4ui xfce4-panel xfconf gtk2 ]; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; - meta = { - homepage = "https://goodies.xfce.org/projects/panel-plugins/${p_name}"; + meta = with stdenv.lib; { + homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "Cyclically spawns a command and captures its output"; platforms = platforms.linux; maintainers = [ maintainers.AndersonTorres ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-hardware-monitor-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-hardware-monitor-plugin.nix index 40810abfc079..83084b626612 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-hardware-monitor-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-hardware-monitor-plugin.nix @@ -1,5 +1,5 @@ { stdenv, fetchurl, pkgconfig, intltool, autoreconfHook, gnome2, gtkmm2, - libgtop, libxfce4ui, libxfce4util, xfce4-panel, lm_sensors + libgtop, libxfce4ui, libxfce4util, xfce4-panel, lm_sensors, xfce }: stdenv.mkDerivation rec { @@ -30,11 +30,11 @@ stdenv.mkDerivation rec { enableParallelBuilding = true; - meta = { + meta = with stdenv.lib; { homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "Hardware monitor plugin for the XFCE4 panel"; - license = stdenv.lib.licenses.gpl3; - platforms = stdenv.lib.platforms.unix; - maintainers = [ stdenv.lib.maintainers.romildo ]; + license = licenses.gpl3; + platforms = platforms.unix; + maintainers = [ maintainers.romildo ]; }; } diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-mailwatch-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-mailwatch-plugin.nix index 058f25917161..b63224f87086 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-mailwatch-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-mailwatch-plugin.nix @@ -1,24 +1,31 @@ { stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, - xfconf, gtk2, exo, gnutls, libgcrypt }: + xfconf, gtk2, exo, gnutls, libgcrypt, xfce }: + +let + category = "panel-plugins"; +in -with stdenv.lib; stdenv.mkDerivation rec { - p_name = "xfce4-mailwatch-plugin"; - ver_maj = "1.2"; - ver_min = "0"; + pname = "xfce4-mailwatch-plugin"; + version = "1.2.0"; src = fetchurl { - url = "mirror://xfce/src/panel-plugins/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "1bfw3smwivr9mzdyq768biqrl4aq94zqi3xjzq6kqnd8561cqjk2"; }; - name = "${p_name}-${ver_maj}.${ver_min}"; nativeBuildInputs = [ pkgconfig ]; buildInputs = [ intltool libxfce4util libxfce4ui xfce4-panel xfconf gtk2 exo gnutls libgcrypt ]; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; - meta = { - homepage = "https://goodies.xfce.org/projects/panel-plugins/${p_name}"; + meta = with stdenv.lib; { + homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "Mailwatch plugin for Xfce panel"; platforms = platforms.linux; maintainers = [ ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-mpc-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-mpc-plugin.nix index b936d2e441c0..7d7b1981c52a 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-mpc-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-mpc-plugin.nix @@ -1,24 +1,31 @@ { stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, - xfconf, gtk2, exo }: + xfconf, gtk2, exo, xfce }: + +let + category = "panel-plugins"; +in -with stdenv.lib; stdenv.mkDerivation rec { - p_name = "xfce4-mpc-plugin"; - ver_maj = "0.4"; - ver_min = "5"; - name = "${p_name}-${ver_maj}.${ver_min}"; + pname = "xfce4-mpc-plugin"; + version = "0.4.5"; src = fetchurl { - url = "mirror://xfce/src/panel-plugins/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "1kvgq1pq7cykqdc3227dq0izad093ppfw3nfsrcp9i8mi6i5f7z7"; }; nativeBuildInputs = [ pkgconfig ]; buildInputs = [ intltool libxfce4util libxfce4ui xfce4-panel xfconf gtk2 exo ]; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; - meta = { - homepage = "https://goodies.xfce.org/projects/panel-plugins/${p_name}"; + meta = with stdenv.lib; { + homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "MPD plugin for Xfce panel"; platforms = platforms.linux; maintainers = [ ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-netload-plugin/default.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-netload-plugin/default.nix index d774649b5369..09e686a9536c 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-netload-plugin/default.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-netload-plugin/default.nix @@ -1,10 +1,10 @@ { mkXfceDerivation, gtk3, libxfce4ui, libxfce4util, xfce4-panel, xfconf }: -mkXfceDerivation rec { +mkXfceDerivation { category = "panel-plugins"; pname = "xfce4-netload-plugin"; version = "1.3.1"; - rev = "version-${version}"; + rev-prefix = "version-"; sha256 = "0nm8advafw4jpc9p1qszyfqa56194sz51z216rdh4c6ilcrrpy1h"; buildInputs = [ gtk3 libxfce4ui libxfce4util xfce4-panel xfconf ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-notes-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-notes-plugin.nix index 516d86f56abb..1b7e66936fab 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-notes-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-notes-plugin.nix @@ -1,22 +1,29 @@ -{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2, libunique }: +{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2, libunique, xfce }: + +let + category = "panel-plugins"; +in -with stdenv.lib; stdenv.mkDerivation rec { - p_name = "xfce4-notes-plugin"; - ver_maj = "1.7"; - ver_min = "7"; + pname = "xfce4-notes-plugin"; + version = "1.7.7"; src = fetchurl { - url = "mirror://xfce/src/panel-plugins/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "05sjbwgch1j93m3r23ksbjnpfk11sf7xjmbb9pm5vl3snc2s3fm7"; }; - name = "${p_name}-${ver_maj}.${ver_min}"; nativeBuildInputs = [ pkgconfig ]; buildInputs = [ intltool libxfce4util libxfce4ui xfce4-panel xfconf gtk2 libunique ]; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; - meta = { - homepage = "https://goodies.xfce.org/projects/panel-plugins/${p_name}"; + meta = with stdenv.lib; { + homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "Sticky notes plugin for Xfce panel"; platforms = platforms.linux; maintainers = [ maintainers.AndersonTorres ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-sensors-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-sensors-plugin.nix index 56cad888168d..14cab3d932e8 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-sensors-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-sensors-plugin.nix @@ -1,15 +1,17 @@ { stdenv, fetchurl, pkgconfig, intltool, gtk2, libxfce4ui, - libxfce4util, xfce4-panel, libnotify, lm_sensors, hddtemp, netcat-gnu + libxfce4util, xfce4-panel, libnotify, lm_sensors, hddtemp, netcat-gnu, xfce }: +let + category = "panel-plugins"; +in + stdenv.mkDerivation rec { - name = "${pname}-${ver_maj}.${ver_min}"; pname = "xfce4-sensors-plugin"; - ver_maj = "1.2"; - ver_min = "6"; + version = "1.2.6"; src = fetchurl { - url = "mirror://xfce/src/panel-plugins/${pname}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "1h0vpqxcziml3gwrbvd8xvy1mwh9mf2a68dvxsy03rs5pm1ghpi3"; }; @@ -35,12 +37,18 @@ stdenv.mkDerivation rec { "--with-pathhddtemp=${hddtemp}/bin/hddtemp" "--with-pathnetcat=${netcat-gnu}/bin/netcat" ]; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; - meta = { + meta = with stdenv.lib; { homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "A panel plug-in for different sensors using acpi, lm_sensors and hddtemp"; - license = stdenv.lib.licenses.gpl2; - platforms = stdenv.lib.platforms.unix; - maintainers = [ stdenv.lib.maintainers.romildo ]; + license = licenses.gpl2; + platforms = platforms.unix; + maintainers = [ maintainers.romildo ]; }; } diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-systemload-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-systemload-plugin.nix index 95fb9358f946..1ff0bc2efbae 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-systemload-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-systemload-plugin.nix @@ -1,22 +1,29 @@ -{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, gtk2}: +{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, gtk2, xfce }: + +let + category = "panel-plugins"; +in -with stdenv.lib; stdenv.mkDerivation rec { - p_name = "xfce4-systemload-plugin"; - ver_maj = "1.1"; - ver_min = "2"; + pname = "xfce4-systemload-plugin"; + version = "1.1.2"; src = fetchurl { - url = "mirror://xfce/src/panel-plugins/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "0z4as6sxdz93d4jpgv0665dg4sykfvc5068mc689phlfl2rvcsdl"; }; - name = "${p_name}-${ver_maj}.${ver_min}"; nativeBuildInputs = [ pkgconfig ]; buildInputs = [ intltool libxfce4util libxfce4ui xfce4-panel gtk2 ]; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; - meta = { - homepage = "https://goodies.xfce.org/projects/panel-plugins/${p_name}"; + meta = with stdenv.lib; { + homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "System load plugin for Xfce panel"; platforms = platforms.linux; maintainers = [ maintainers.AndersonTorres ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-timer-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-timer-plugin.nix index 4070156c2239..ae08fd3aeaee 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-timer-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-timer-plugin.nix @@ -1,17 +1,18 @@ { stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel -, libxfce4ui, xfconf, gtk2, hicolor-icon-theme }: +, libxfce4ui, xfconf, gtk2, hicolor-icon-theme, xfce }: + +let + category = "panel-plugins"; +in -with stdenv.lib; stdenv.mkDerivation rec { - p_name = "xfce4-timer-plugin"; - ver_maj = "1.6"; - ver_min = "0"; + pname = "xfce4-timer-plugin"; + version = "1.6.0"; src = fetchurl { - url = "mirror://xfce/src/panel-plugins/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "0z46gyw3ihcd1jf0m5z1dsc790xv1cpi8mk1dagj3i4v14gx5mrr"; }; - name = "${p_name}-${ver_maj}.${ver_min}"; buildInputs = [ intltool libxfce4util libxfce4ui xfce4-panel xfconf gtk2 hicolor-icon-theme ]; @@ -19,9 +20,15 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ pkgconfig ]; hardeningDisable = [ "format" ]; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; - meta = { - homepage = "https://goodies.xfce.org/projects/panel-plugins/${p_name}"; + meta = with stdenv.lib; { + homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "A simple XFCE panel plugin that lets the user run an alarm at a specified time or at the end of a specified countdown period"; platforms = platforms.linux; license = licenses.gpl2; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/default.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/default.nix index 43e943f194ac..bd0db543cf66 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/default.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/default.nix @@ -41,6 +41,12 @@ stdenv.mkDerivation rec { mv cmake/FallbackVersion.cmake.in cmake/FallbackVersion.cmake ''; + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.gitLister src.meta.homepage; + }; + meta = with stdenv.lib; { description = "Global Menu applet for XFCE4"; license = licenses.lgpl3; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-verve-plugin/default.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-verve-plugin/default.nix index 288aaddfb982..5a98173ea00c 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-verve-plugin/default.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-verve-plugin/default.nix @@ -1,10 +1,10 @@ { lib, mkXfceDerivation, gtk3, libxfce4ui, pcre, libxfce4util, xfce4-panel, xfconf }: -mkXfceDerivation rec { +mkXfceDerivation { category = "panel-plugins"; pname = "xfce4-verve-plugin"; version = "2.0.0"; - rev = version; + rev-prefix = ""; sha256 = "09vpa6m0ah7pgmra094c16vb79xrcwva808g6zpawwrhcwz85lcz"; buildInputs = [ gtk3 libxfce4ui pcre libxfce4util xfce4-panel ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-weather-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-weather-plugin.nix index 0914c4cb7d97..f32efb01edd1 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-weather-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-weather-plugin.nix @@ -1,14 +1,16 @@ { stdenv, fetchurl, pkgconfig, intltool, gtk2, libxml2, libsoup, upower, -libxfce4ui, libxfce4util, xfce4-panel, hicolor-icon-theme }: + libxfce4ui, libxfce4util, xfce4-panel, hicolor-icon-theme, xfce }: + +let + category = "panel-plugins"; +in stdenv.mkDerivation rec { - name = "${p_name}-${ver_maj}.${ver_min}"; - p_name = "xfce4-weather-plugin"; - ver_maj = "0.8"; - ver_min = "10"; + pname = "xfce4-weather-plugin"; + version = "0.8.10"; src = fetchurl { - url = "mirror://xfce/src/panel-plugins/${p_name}/${ver_maj}/${name}.tar.bz2"; + url = "mirror://xfce/src/${category}/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "1f7ac2zr5s5w6krdpgsq252wxhhmcblia3j783132ilh8k246vgf"; }; @@ -18,12 +20,18 @@ stdenv.mkDerivation rec { xfce4-panel hicolor-icon-theme ]; enableParallelBuilding = true; + + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.archiveLister category pname; + }; - meta = { - homepage = "https://goodies.xfce.org/projects/panel-plugins/${p_name}"; + meta = with stdenv.lib; { + homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "Weather plugin for the Xfce desktop environment"; - license = stdenv.lib.licenses.gpl2Plus; - platforms = stdenv.lib.platforms.unix; - maintainers = [ stdenv.lib.maintainers.romildo ]; + license = licenses.gpl2Plus; + platforms = platforms.unix; + maintainers = [ maintainers.romildo ]; }; } diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-whiskermenu-plugin/default.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-whiskermenu-plugin/default.nix index 884b8ee3a294..262093af69f1 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-whiskermenu-plugin/default.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-whiskermenu-plugin/default.nix @@ -1,10 +1,10 @@ { mkXfceDerivation, gtk3, glib, cmake, exo, garcon, libxfce4ui, libxfce4util, xfce4-panel, xfconf }: -mkXfceDerivation rec { +mkXfceDerivation { category = "panel-plugins"; pname = "xfce4-whiskermenu-plugin"; version = "2.4.3"; - rev = "v${version}"; + rev-prefix = "v"; sha256 = "1cs3fps1bj0dd5az7fwrvw1xl3y621qk4dma3n73p7rr19j7fpsn"; nativeBuildInputs = [ cmake ]; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-windowck-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-windowck-plugin.nix index eba7be91ef9d..ceeac724cf38 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-windowck-plugin.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-windowck-plugin.nix @@ -1,17 +1,16 @@ { stdenv, fetchFromGitHub, pkgconfig, intltool, python3, imagemagick, libwnck, gtk2 -, exo, libxfce4ui, libxfce4util, xfce4-panel, xfconf, xfce4-dev-tools }: +, exo, libxfce4ui, libxfce4util, xfce4-panel, xfconf, xfce4-dev-tools, xfce }: stdenv.mkDerivation rec { - p_name = "xfce4-windowck-plugin"; + pname = "xfce4-windowck-plugin"; version = "0.4.4"; src = fetchFromGitHub { owner = "cedl38"; - repo = "xfce4-windowck-plugin"; + repo = pname; rev = "v${version}"; sha256 = "0c6a1ibh39dpq9x0dha5lsg0vzmgaf051fgwz0nlky0s94nwzvgv"; }; - name = "${p_name}-${version}"; nativeBuildInputs = [ pkgconfig ]; buildInputs = [ intltool python3 imagemagick libwnck gtk2 @@ -24,8 +23,15 @@ stdenv.mkDerivation rec { enableParallelBuilding = true; + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.${pname}"; + versionLister = xfce.gitLister src.meta.homepage; + rev-prefix = "v"; + }; + meta = with stdenv.lib; { - homepage = "https://goodies.xfce.org/projects/panel-plugins/${p_name}"; + homepage = "https://goodies.xfce.org/projects/panel-plugins/${pname}"; description = "Set of two plugins which allows you to put the maximized window title and windows buttons on the panel"; license = licenses.gpl2Plus; platforms = platforms.unix; diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-xkb-plugin/default.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-xkb-plugin/default.nix index 4497a7b0e36a..a08621594890 100644 --- a/pkgs/desktops/xfce/panel-plugins/xfce4-xkb-plugin/default.nix +++ b/pkgs/desktops/xfce/panel-plugins/xfce4-xkb-plugin/default.nix @@ -1,10 +1,10 @@ { lib, mkXfceDerivation, gtk3, librsvg, libwnck3, libxklavier, garcon, libxfce4ui, libxfce4util, xfce4-panel, xfconf }: -mkXfceDerivation rec { +mkXfceDerivation { category = "panel-plugins"; pname = "xfce4-xkb-plugin"; version = "0.8.1"; - rev = version; + rev-prefix = ""; sha256 = "1gyky4raynp2ggdnq0g96c6646fjm679fzipcsmf1q0aymr8d5ky"; buildInputs = [ garcon gtk3 librsvg libxfce4ui libxfce4util libxklavier libwnck3 xfce4-panel xfconf ]; diff --git a/pkgs/desktops/xfce/thunar-plugins/archive/default.nix b/pkgs/desktops/xfce/thunar-plugins/archive/default.nix index e3c72d3b50e2..6b255dc72012 100644 --- a/pkgs/desktops/xfce/thunar-plugins/archive/default.nix +++ b/pkgs/desktops/xfce/thunar-plugins/archive/default.nix @@ -1,6 +1,5 @@ { stdenv , mkXfceDerivation -, fetchFromGitHub , gtk3 , thunar , exo @@ -9,7 +8,7 @@ , gettext }: -mkXfceDerivation rec { +mkXfceDerivation { category = "thunar-plugins"; pname = "thunar-archive-plugin"; version = "0.4.0"; diff --git a/pkgs/desktops/xfce/thunar-plugins/dropbox/default.nix b/pkgs/desktops/xfce/thunar-plugins/dropbox/default.nix index 8674c586552c..61e9d94acc5d 100644 --- a/pkgs/desktops/xfce/thunar-plugins/dropbox/default.nix +++ b/pkgs/desktops/xfce/thunar-plugins/dropbox/default.nix @@ -5,6 +5,7 @@ , thunar , cmake , ninja +, xfce }: stdenv.mkDerivation rec { @@ -31,6 +32,12 @@ stdenv.mkDerivation rec { enableParallelBuilding = true; + passthru.updateScript = xfce.updateScript { + inherit pname version; + attrPath = "xfce.thunar-dropbox-plugin"; + versionLister = xfce.gitLister src.meta.homepage; + }; + meta = with stdenv.lib; { homepage = "https://github.com/Jeinzi/thunar-dropbox"; description = "A plugin that adds context-menu items for Dropbox to Thunar"; From a097de3e7309bfdb54dfdb50e06b9835e43f1833 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Romildo=20Malaquias?= Date: Mon, 13 Apr 2020 19:16:15 -0300 Subject: [PATCH 6/6] common-updater-scripts: ignore update-git-commits.txt It is generated by common-updater/update-script.nix --- .gitignore | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.gitignore b/.gitignore index ca00bc4df574..05ada15f43a0 100644 --- a/.gitignore +++ b/.gitignore @@ -16,3 +16,6 @@ result-* /pkgs/development/libraries/qt-5/*/tmp/ /pkgs/desktops/kde-5/*/tmp/ /pkgs/development/mobile/androidenv/xml/* + +# generated by pkgs/common-updater/update-script.nix +update-git-commits.txt