tradingview: 2.6.1 -> 2.6.3

This commit is contained in:
ProminentRetail 2023-11-07 12:29:01 +11:00
parent ab57b2cc64
commit 7bdc9489de
No known key found for this signature in database
GPG Key ID: 301B0D2B633C846F
2 changed files with 11 additions and 10 deletions

View File

@ -20,13 +20,14 @@
, xorg
}:
stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
pname = "tradingview";
version = "2.6.1";
revision = "44";
version = "2.6.3";
revision = "46";
src = fetchurl {
url = "https://api.snapcraft.io/api/v1/snaps/download/nJdITJ6ZJxdvfu8Ch7n5kH5P99ClzBYV_${revision}.snap";
hash = "sha512-Hd00TWjPskd0QDzpOSwQCuMw20nW4n1xxRkT1rA95pzbXtw7XFxrJdMWkzWDbucuokU2qR2b5tovAHAgw9E0tQ==";
url = "https://api.snapcraft.io/api/v1/snaps/download/nJdITJ6ZJxdvfu8Ch7n5kH5P99ClzBYV_${finalAttrs.revision}.snap";
hash = "sha512-jg3VPSfyjh+sYbrLDkqqy1tdUaxuEanQWW1U2SHUQ555tvn9X34pP8uarCFWqu9oye/7KF6KDEjjoIqirUKafw==";
};
nativeBuildInputs = [
@ -75,7 +76,7 @@ stdenv.mkDerivation rec {
cp squashfs-root/meta/gui/icon.png $out/share/icons/tradingview.png
mkdir $out/bin
makeBinaryWrapper $out/share/tradingview/tradingview $out/bin/tradingview --prefix LD_LIBRARY_PATH : ${ lib.makeLibraryPath buildInputs }
makeBinaryWrapper $out/share/tradingview/tradingview $out/bin/tradingview --prefix LD_LIBRARY_PATH : ${ lib.makeLibraryPath finalAttrs.buildInputs }
runHook postInstall
'';
@ -90,4 +91,4 @@ stdenv.mkDerivation rec {
platforms = [ "x86_64-linux" ];
mainProgram = "tradingview";
};
}
})

View File

@ -26,7 +26,7 @@ echo "Latest release is $upstream_version from $last_updated."
#
nixpkgs="$(git rev-parse --show-toplevel)"
tradingview_nix="$nixpkgs/pkgs/applications/finance/tradingview/default.nix"
tradingview_nix="$nixpkgs/pkgs/by-name/tr/tradingview/package.nix"
current_nix_version=$(
grep 'version\s*=' "$tradingview_nix" \
| sed -Ene 's/.*"(.*)".*/\1/p'
@ -44,10 +44,10 @@ fi
#
echo "Updating from ${current_nix_version} to ${upstream_version}, released ${last_updated}"
echo 's/hash\s*=\s*"[^"]*"\s*;/hash = "'"${sri}"'";/'
sed --regexp-extended \
-e 's/revision\s*=\s*"[0-9]+"\s*;/revision = "'"${revision}"'";/' \
-e 's/hash\s*=\s*"[^"]*"\s*;/hash = "'"${sri}"'";/' \
-e 's#hash\s*=\s*"[^"]*"\s*;#hash = "'"${sri}"'";#' \
-e 's/version\s*=\s*".*"\s*;/version = "'"${upstream_version}"'";/' \
-i "$tradingview_nix"