diff options
author | github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> | 2024-04-07 00:14:37 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-07 00:14:37 +0000 |
commit | dd538d227e3cfcaa671fabc5ae9f6fe06654d67d (patch) | |
tree | 73005db975eba6d1d4f0cdb5815d0b1846827bb0 /pkgs/data | |
parent | 1b23f872be0153ef418336c193443bef8a7ef40d (diff) | |
parent | 82ccaa1ef62e8c31b634086d0a261c3b46275587 (diff) |
Merge master into haskell-updates
Diffstat (limited to 'pkgs/data')
-rw-r--r-- | pkgs/data/fonts/sketchybar-app-font/default.nix | 101 | ||||
-rw-r--r-- | pkgs/data/themes/catppuccin-gtk/default.nix | 13 | ||||
-rw-r--r-- | pkgs/data/themes/catppuccin-sddm-corners/default.nix | 3 | ||||
-rw-r--r-- | pkgs/data/themes/dracula-theme/default.nix | 6 |
4 files changed, 96 insertions, 27 deletions
diff --git a/pkgs/data/fonts/sketchybar-app-font/default.nix b/pkgs/data/fonts/sketchybar-app-font/default.nix index cd9af9a9c5f47..c131069e9e748 100644 --- a/pkgs/data/fonts/sketchybar-app-font/default.nix +++ b/pkgs/data/fonts/sketchybar-app-font/default.nix @@ -1,34 +1,91 @@ +let + artifacts = [ "shell" "lua" "font" ]; +in { lib , stdenvNoCC , fetchurl +, common-updater-scripts +, curl +, jq +, writeShellScript +, artifactList ? artifacts }: +lib.checkListOfEnum "sketchybar-app-font: artifacts" artifacts artifactList + stdenvNoCC.mkDerivation + (finalAttrs: + let + selectedSources = map (artifact: builtins.getAttr artifact finalAttrs.passthru.sources) artifactList; + in + { + pname = "sketchybar-app-font"; + version = "2.0.16"; -stdenvNoCC.mkDerivation (finalAttrs: { - pname = "sketchybar-app-font"; - version = "2.0.12"; + srcs = selectedSources; - src = fetchurl { - url = "https://github.com/kvndrsslr/sketchybar-app-font/releases/download/v${finalAttrs.version}/sketchybar-app-font.ttf"; - hash = "sha256-qACf4eWDeubBmJV0ApWidp2ESLREi5qiLliWCXoMBKY="; - }; + unpackPhase = '' + runHook preUnpack - dontUnpack = true; + for s in $selectedSources; do + b=$(basename $s) + cp $s ''${b#*-} + done - installPhase = '' - runHook preInstall + runHook postUnpack + ''; + + installPhase = '' + runHook preInstall + + '' + lib.optionalString (lib.elem "font" artifactList) '' + install -Dm644 ${finalAttrs.passthru.sources.font} "$out/share/fonts/truetype/sketchybar-app-font.ttf" - install -Dm644 $src $out/share/fonts/truetype/sketchybar-app-font.ttf + '' + lib.optionalString (lib.elem "shell" artifactList) '' + install -Dm755 ${finalAttrs.passthru.sources.shell} "$out/bin/icon_map.sh" - runHook postInstall - ''; + '' + lib.optionalString (lib.elem "lua" artifactList) '' + install -Dm644 ${finalAttrs.passthru.sources.lua} "$out/lib/sketchybar-app-font/icon_map.lua" - meta = { - description = "A ligature-based symbol font and a mapping function for sketchybar"; - longDescription = '' - A ligature-based symbol font and a mapping function for sketchybar, inspired by simple-bar's usage of community-contributed minimalistic app icons. + runHook postInstall ''; - homepage = "https://github.com/kvndrsslr/sketchybar-app-font"; - license = lib.licenses.cc0; - maintainers = with lib.maintainers; [ khaneliman ]; - }; -}) + + passthru = { + sources = { + font = fetchurl { + url = "https://github.com/kvndrsslr/sketchybar-app-font/releases/download/v${finalAttrs.version}/sketchybar-app-font.ttf"; + hash = "sha256-mZ3LmkL54NNQzXuCyWVNlAIod3T5/aGKvnLZjZ/GYdw="; + }; + lua = fetchurl { + url = "https://github.com/kvndrsslr/sketchybar-app-font/releases/download/v${finalAttrs.version}/icon_map.lua"; + hash = "sha256-8daDECZ8hsoyh4Rp3xbkYgPSamCylrzf8zzyu/iwZEc="; + }; + shell = fetchurl { + url = "https://github.com/kvndrsslr/sketchybar-app-font/releases/download/v${finalAttrs.version}/icon_map.sh"; + hash = "sha256-h0rGkzy1smDL2guvvgeUVUD0q4n9LDKDLQJahbWHgWA="; + }; + }; + + updateScript = writeShellScript "update-sketchybar-app-font" '' + set -o errexit + export PATH="${lib.makeBinPath [ curl jq common-updater-scripts ]}" + NEW_VERSION=$(curl --silent https://api.github.com/repos/kvndrsslr/sketchybar-app-font/releases/latest | jq '.tag_name | ltrimstr("v")' --raw-output) + if [[ "${finalAttrs.version}" = "$NEW_VERSION" ]]; then + echo "The new version same as the old version." + exit 0 + fi + for artifact in ${lib.escapeShellArgs (lib.mapAttrsToList(a: _: a) finalAttrs.passthru.sources)}; do + update-source-version "sketchybar-app-font" "0" "${lib.fakeHash}" --source-key="sources.$artifact" + update-source-version "sketchybar-app-font" "$NEW_VERSION" --source-key="sources.$artifact" + done + ''; + }; + + meta = { + description = "A ligature-based symbol font and a mapping function for sketchybar"; + longDescription = '' + A ligature-based symbol font and a mapping function for sketchybar, inspired by simple-bar's usage of community-contributed minimalistic app icons. + ''; + homepage = "https://github.com/kvndrsslr/sketchybar-app-font"; + license = lib.licenses.cc0; + maintainers = with lib.maintainers; [ khaneliman ]; + }; + }) diff --git a/pkgs/data/themes/catppuccin-gtk/default.nix b/pkgs/data/themes/catppuccin-gtk/default.nix index 0dc881942bccb..a3262dcf22e2e 100644 --- a/pkgs/data/themes/catppuccin-gtk/default.nix +++ b/pkgs/data/themes/catppuccin-gtk/default.nix @@ -1,6 +1,7 @@ { lib , stdenvNoCC , fetchFromGitHub +, fetchpatch , gtk3 , colloid-gtk-theme , gnome-themes-extra @@ -29,19 +30,27 @@ lib.checkListOfEnum "${pname}: tweaks" validTweaks tweaks stdenvNoCC.mkDerivation rec { inherit pname; - version = "0.7.1"; + version = "0.7.2"; src = fetchFromGitHub { owner = "catppuccin"; repo = "gtk"; rev = "v${version}"; - hash = "sha256-V3JasiHaATbVDQJeJPeFq5sjbkQnSMbDRWsaRzGccXU="; + hash = "sha256-7EvKcyh9gH/QbiXKlyAKMSBXMF3DmbHD+wJD3Sq39DE="; }; nativeBuildInputs = [ gtk3 sassc ]; patches = [ ./colloid-src-git-reset.patch + + # Can be removed next release + # Adds compatibility with the 2.x.x versions of the catppuccin python package + (fetchpatch { + name = "catppuccin-python-compatibility.patch"; + url = "https://github.com/catppuccin/gtk/commit/355e12387f73b27cf4734a6a3eb431554fabb74f.patch"; + hash = "sha256-4vgZbNeGMtsQEitIWDCVb5o4fAjhVu3iIUttUYqtHPc="; + }) ]; buildInputs = [ diff --git a/pkgs/data/themes/catppuccin-sddm-corners/default.nix b/pkgs/data/themes/catppuccin-sddm-corners/default.nix index eca8bac5e4980..fe2fa9b9fb774 100644 --- a/pkgs/data/themes/catppuccin-sddm-corners/default.nix +++ b/pkgs/data/themes/catppuccin-sddm-corners/default.nix @@ -1,6 +1,7 @@ { lib , stdenvNoCC , fetchFromGitHub +, unstableGitUpdater }: stdenvNoCC.mkDerivation { @@ -26,6 +27,8 @@ stdenvNoCC.mkDerivation { runHook postInstall ''; + passthru.updateScript = unstableGitUpdater { }; + meta = { description = "Soothing pastel theme for SDDM based on corners theme."; homepage = "https://github.com/khaneliman/sddm-catppuccin-corners"; diff --git a/pkgs/data/themes/dracula-theme/default.nix b/pkgs/data/themes/dracula-theme/default.nix index cfc3689d7cc3e..2e7ed4757a580 100644 --- a/pkgs/data/themes/dracula-theme/default.nix +++ b/pkgs/data/themes/dracula-theme/default.nix @@ -2,7 +2,7 @@ let themeName = "Dracula"; - version = "unstable-2024-03-13"; + version = "unstable-2024-03-31"; in stdenvNoCC.mkDerivation { pname = "dracula-theme"; @@ -11,8 +11,8 @@ stdenvNoCC.mkDerivation { src = fetchFromGitHub { owner = "dracula"; repo = "gtk"; - rev = "573f88083ae759f480860552f66e9951077bc428"; - hash = "sha256-BQPlKcsfhpVTtVrwS9yVpIkujF6vM/ToIDmy9X60Mhs="; + rev = "c21f12be904fe55336397fc80feb1a8c8216dca2"; + hash = "sha256-UbipHarnLkCDpUhQOP/uJlXSJ5zHptpNpLPgYwDz+1A="; }; propagatedUserEnvPkgs = [ |