tidal-hifi: 6.0.1 -> 6.1.0, add updateScript (#486137)

This commit is contained in:
Michael Daniels
2026-02-11 20:32:59 +00:00
committed by GitHub
2 changed files with 36 additions and 8 deletions
+4 -1
View File
@@ -21,7 +21,10 @@ in
name = "castlabs-electron-${version}";
inherit version;
pname = "castlabs-electron";
passthru.dist = final.finalPackage.outPath;
passthru = {
dist = final.finalPackage.outPath;
src = final.finalPackage;
};
meta = {
license = lib.licenses.unfreeRedistributable;
+32 -7
View File
@@ -42,13 +42,16 @@
libsecret,
libpulseaudio,
speechd-minimal,
writeShellScript,
yq,
curl,
nix-update,
common-updater-scripts,
castlabs-electron ? callPackage ./electron.nix { },
}:
let
version = "6.0.1";
electronLibPath = lib.makeLibraryPath [
alsa-lib
at-spi2-atk
@@ -89,13 +92,13 @@ let
in
buildNpmPackage (finalAttrs: {
pname = "tidal-hifi";
inherit version;
version = "6.1.0";
src = fetchFromGitHub {
owner = "Mastermindzh";
repo = "tidal-hifi";
tag = version;
hash = "sha256-wc8KsZGNjaIG9sijVGEzoJ7ZTmu4xX8b/ETjlMkNyDs=";
tag = finalAttrs.version;
hash = "sha256-wNYcjFbePWhtkPqR4byGE+FlRNEUv2/EoTYQE2JRAyE=";
};
nativeBuildInputs = [
@@ -104,7 +107,7 @@ buildNpmPackage (finalAttrs: {
copyDesktopItems
];
npmDepsHash = "sha256-lec3XcdZc+lcp/b175m/4dgBPLJCvlUPN8Ttqdehgw4=";
npmDepsHash = "sha256-OTETAe9RW3tBkGS7AlboxX/hUiGax7lxbtdXwRnr9X8=";
forceGitDeps = true;
makeCacheWritable = true;
@@ -187,8 +190,30 @@ buildNpmPackage (finalAttrs: {
"''${gappsWrapperArgs[@]}"
'';
passthru = {
inherit castlabs-electron;
updateScript = writeShellScript "update" ''
set -xeuo pipefail
export PATH="${
lib.makeBinPath [
nix-update
yq
curl
common-updater-scripts
]
}:$PATH"
nix-update 'tidal-hifi'
TIDAL_VERSION="$(nix-instantiate --eval --raw -A 'tidal-hifi.version')"
NEW_VERSION="$(curl --silent "https://raw.githubusercontent.com/Mastermindzh/tidal-hifi/refs/tags/$TIDAL_VERSION/build/electron-builder.base.yml" | yq -r '.electronVersion')"
NIXPKGS_ALLOW_UNFREE=1 update-source-version tidal-hifi.castlabs-electron "$NEW_VERSION"
'';
};
meta = {
changelog = "https://github.com/Mastermindzh/tidal-hifi/releases/tag/${version}";
changelog = "https://github.com/Mastermindzh/tidal-hifi/releases/tag/${finalAttrs.version}";
description = "Web version of Tidal running in Electron with Hi-Fi support thanks to Widevine";
homepage = "https://github.com/Mastermindzh/tidal-hifi";
license = lib.licenses.mit;