From 28ec440896e39a2a9695b28dafe2242cefbd3945 Mon Sep 17 00:00:00 2001 From: sadan <117494111+sadan4@users.noreply.github.com> Date: Wed, 29 May 2024 15:28:48 -0400 Subject: [PATCH] 155 current 2024-05-29 15:28:39 24.11.20240524.bfb7a88 6.9.1-zen1 * --- common/pkgs.nix | 2 +- customPackages/default.nix | 2 +- customPackages/discord/default.nix | 36 +++++------ customPackages/discord/linux.nix | 99 ++++++------------------------ customPackages/vesktop/result | 1 - 5 files changed, 38 insertions(+), 102 deletions(-) delete mode 120000 customPackages/vesktop/result diff --git a/common/pkgs.nix b/common/pkgs.nix index 8d30c06..00dbadc 100644 --- a/common/pkgs.nix +++ b/common/pkgs.nix @@ -34,7 +34,7 @@ in nodejs_22 ]; gui = with pkgs;[ - pkgs.discord + cpkg.discord xsel spotify pulseaudioFull diff --git a/customPackages/default.nix b/customPackages/default.nix index 7b417c6..07296b1 100644 --- a/customPackages/default.nix +++ b/customPackages/default.nix @@ -1,6 +1,6 @@ { pkgs }: rec{ # discord = nixpkgs.callPackage ./discord { }; - discord = pkgs.callPackage ./discord/default.nix { }; + discord = pkgs.callPackage ./discord/default.nix { inherit vencord; }; vesktop = pkgs.callPackage ./vesktop/default.nix { inherit vencord; }; vencord = pkgs.callPackage ./vencord/default.nix { }; } diff --git a/customPackages/discord/default.nix b/customPackages/discord/default.nix index 6db934c..e8763ba 100644 --- a/customPackages/discord/default.nix +++ b/customPackages/discord/default.nix @@ -1,53 +1,53 @@ -{ branch ? "stable", callPackage, fetchurl, lib, stdenv }: +{vencord, branch ? "stable", callPackage, fetchurl, lib, stdenv }: let versions = if stdenv.isLinux then { - stable = "0.0.50"; - ptb = "0.0.80"; - canary = "0.0.357"; - development = "0.0.17"; + stable = "0.0.53"; + ptb = "0.0.84"; + canary = "0.0.382"; + development = "0.0.18"; } else { - stable = "0.0.301"; - ptb = "0.0.109"; - canary = "0.0.477"; - development = "0.0.39"; + stable = "0.0.303"; + ptb = "0.0.113"; + canary = "0.0.492"; + development = "0.0.40"; }; version = versions.${branch}; srcs = rec { x86_64-linux = { stable = fetchurl { url = "https://dl.discordapp.net/apps/linux/${version}/discord-${version}.tar.gz"; - hash = "sha256-6VXdVLk7Z8NGQMiSdgBRd8NIueUktkId6BXYKNABb+4="; + hash = "sha256-HD8bDFUV3YGk/t3Rbm26nXWDvUjjIf4ykdO6YGDtvTU="; }; ptb = fetchurl { url = "https://dl-ptb.discordapp.net/apps/linux/${version}/discord-ptb-${version}.tar.gz"; - hash = "sha256-y/ntnHIYcY35Jszh0PrFy395eJ5dBWwLNpzHMoSZuNA="; + hash = "sha256-0bOsmy2ldZT7S4tVOkihE5eLiujXC/ugF8CKXfBXHNU="; }; canary = fetchurl { url = "https://dl-canary.discordapp.net/apps/linux/${version}/discord-canary-${version}.tar.gz"; - hash = "sha256-sDwC5kPzAfvQmsrq6M/GPFtUaT9pNAEB4uGI5Mn3oXs="; + hash = "sha256-MXMq4V+21KPHoCUs5x1rNRbkfw6+3cF7xSSNguiqOfc="; }; development = fetchurl { url = "https://dl-development.discordapp.net/apps/linux/${version}/discord-development-${version}.tar.gz"; - hash = "sha256-AmbaMVi/or+9QLuQO5u5btgKeKdrfo7bzZgGLILwgqo="; + hash = "sha256-SoJ4/jXl0axQyeqv8CPSzM+lBsYq/QelHctRAeoscdA="; }; }; x86_64-darwin = { stable = fetchurl { url = "https://dl.discordapp.net/apps/osx/${version}/Discord.dmg"; - hash = "sha256-h7C1wCKtUGcMFUhoKVdD7Vq9TGUaXfmjlVhwmRdhqYw="; + hash = "sha256-B4r0W//d3761ufQr4PAt4ZuPMrOC7Zfo8Q3lHqKxkJ0="; }; ptb = fetchurl { url = "https://dl-ptb.discordapp.net/apps/osx/${version}/DiscordPTB.dmg"; - hash = "sha256-xxLnzELuI0X2r/weP1K2Bb51uRh1JjR72p7cXzy12Kc="; + hash = "sha256-hdT33jK0nHvY3rIh9i1eDq5j46xS9xInRxzGCUP/hi8="; }; canary = fetchurl { url = "https://dl-canary.discordapp.net/apps/osx/${version}/DiscordCanary.dmg"; - hash = "sha256-xEDtEtZNhOTtz+zRLLQBSeLbntlVAVQsocAGyAaVePM="; + hash = "sha256-74XQu4PGW3eW4wPICGsAVlR4SQkDXJWZ1p/G7Bwq950="; }; development = fetchurl { url = "https://dl-development.discordapp.net/apps/osx/${version}/DiscordDevelopment.dmg"; - hash = "sha256-nZV9LK3eGpXK/2wQKJBn3K2Ud6uBk8aammkeE00rWx0="; + hash = "sha256-uPz3uWPAqp3JeL9E+coMrb2Hc+Zn0YGF9Jw3BTKYRlw="; }; }; aarch64-darwin = x86_64-darwin; @@ -76,7 +76,7 @@ let (_: value: callPackage package (value // { - inherit src version openasar branch; + inherit src version openasar branch vencord; meta = meta // { mainProgram = value.binaryName; }; })) { diff --git a/customPackages/discord/linux.nix b/customPackages/discord/linux.nix index 707aef2..1b45531 100644 --- a/customPackages/discord/linux.nix +++ b/customPackages/discord/linux.nix @@ -1,67 +1,17 @@ -{ pname -, version -, src -, meta -, binaryName -, desktopName -, autoPatchelfHook -, makeDesktopItem -, lib -, stdenv -, wrapGAppsHook -, makeShellWrapper -, alsa-lib -, at-spi2-atk -, at-spi2-core -, atk -, cairo -, cups -, dbus -, expat -, fontconfig -, freetype -, gdk-pixbuf -, glib -, gtk3 -, libcxx -, libdrm -, libglvnd -, libnotify -, libpulseaudio -, libuuid -, libX11 -, libXScrnSaver -, libXcomposite -, libXcursor -, libXdamage -, libXext -, libXfixes -, libXi -, libXrandr -, libXrender -, libXtst -, libxcb -, libxshmfence -, mesa -, nspr -, nss -, pango -, systemd -, libappindicator-gtk3 -, libdbusmenu -, writeScript -, python3 -, runCommand +{ pname, version, src, meta, binaryName, desktopName, autoPatchelfHook +, makeDesktopItem, lib, stdenv, wrapGAppsHook, makeShellWrapper, alsa-lib, at-spi2-atk +, at-spi2-core, atk, cairo, cups, dbus, expat, fontconfig, freetype, gdk-pixbuf +, glib, gtk3, libcxx, libdrm, libglvnd, libnotify, libpulseaudio, libuuid, libX11 +, libXScrnSaver, libXcomposite, libXcursor, libXdamage, libXext, libXfixes +, libXi, libXrandr, libXrender, libXtst, libxcb, libxshmfence, mesa, nspr, nss +, pango, systemd, libappindicator-gtk3, libdbusmenu, writeScript, python3, runCommand , libunity , speechd , wayland , branch -, withOpenASAR ? false -, openasar -, withVencord ? true -, vencord -, withTTS ? true -}: +, withOpenASAR ? false, openasar +, withVencord ? true, vencord +, withTTS ? true }: let disableBreakingUpdates = runCommand "disable-breaking-updates.py" @@ -172,30 +122,17 @@ stdenv.mkDerivation rec { ln -s "$desktopItem/share/applications" $out/share/ - set -x - set -e - - cp "${./installer}" $out/opt/vencordInstaller - chmod 770 $out/opt/vencordInstaller - patchelf --set-interpreter ${stdenv.cc.bintools.dynamicLinker} \ - $out/opt/vencordInstaller - - VENCORD_USER_DATA_DIR="/home/meyer/.config/Vencord/dist" $out/opt/vencordInstaller -location $out/opt/Discord -install runHook postInstall ''; - postInstall = - '' - # set -x - # set -e - # - # cp "${./installer}" $out/bin/vencordInstaller - # - # chmod +x $out/bin/vencordInstaller - # patchelf --set-interpreter ${stdenv.cc.bintools.dynamicLinker} \ - # $out/bin/vencordInstaller - # $out/bin/vencordInstaller -location $out/opt/Discord -install - ''; + postInstall = lib.strings.optionalString withOpenASAR '' + cp -f ${openasar} $out/opt/${binaryName}/resources/app.asar + '' + lib.strings.optionalString withVencord '' + mv $out/opt/${binaryName}/resources/app.asar $out/opt/${binaryName}/resources/_app.asar + mkdir $out/opt/${binaryName}/resources/app.asar + echo '{"name":"discord","main":"index.js"}' > $out/opt/${binaryName}/resources/app.asar/package.json + echo 'require("${vencord}/patcher.js")' > $out/opt/${binaryName}/resources/app.asar/index.js + ''; desktopItem = makeDesktopItem { name = pname; diff --git a/customPackages/vesktop/result b/customPackages/vesktop/result deleted file mode 120000 index 6554757..0000000 --- a/customPackages/vesktop/result +++ /dev/null @@ -1 +0,0 @@ -/nix/store/hqr3mgpxvjjf04gjldvf3pzwjxqbswlf-vesktop-1.5.2-alpha.1 \ No newline at end of file