Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package discord for openSUSE:Factory:NonFree checked in at 2023-05-04 17:08:15 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory:NonFree/discord (Old) and /work/SRC/openSUSE:Factory:NonFree/.discord.new.1533 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "discord" Thu May 4 17:08:15 2023 rev:30 rq:1084223 version:0.0.27 Changes: -------- --- /work/SRC/openSUSE:Factory:NonFree/discord/discord.changes 2023-04-03 17:44:34.237514591 +0200 +++ /work/SRC/openSUSE:Factory:NonFree/.discord.new.1533/discord.changes 2023-05-04 17:08:42.399708776 +0200 @@ -1,0 +2,14 @@ +Fri Apr 28 01:45:49 UTC 2023 - Luciano Santos <luc1...@opensuse.org> + +- Update to version 0.0.27: + * No upstream release notes. +- Updated Electron to version 24.1.3. +- Update com.discordapp.Discord.appdata.xml +- Add disable-breaking-updates.py script from NixOS/nixpkgs GitHub + repo (based on the version from flathub/com.discordapp.Discord). + This should disable the auto updating mechanism when Discord is + launched, and prevent it from locking out the user when the app + identifies a new version was released upstream, but our package + hasn't being updated yet. + +------------------------------------------------------------------- Old: ---- discord-0.0.26.tar.gz ffmpeg-v13.6.6-linux-x64.zip New: ---- disable-breaking-updates.py discord-0.0.27.tar.gz ffmpeg-v24.1.3-linux-x64.zip ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ discord.spec ++++++ --- /var/tmp/diff_new_pack.QFam5Q/_old 2023-05-04 17:08:45.207725217 +0200 +++ /var/tmp/diff_new_pack.QFam5Q/_new 2023-05-04 17:08:45.211725241 +0200 @@ -25,7 +25,7 @@ # This is to enable build with patent encoumbered codecs. Not allowed in OBS %bcond_with x264 Name: discord -Version: 0.0.26 +Version: 0.0.27 Release: 0 Summary: Voice and Text Chat for Gamers License: SUSE-NonFree @@ -35,6 +35,10 @@ #Source0: https://discordapp.com/api/download?platform=linux&format=tar.gz Source2: discord-symbolic.svg Source3: https://raw.githubusercontent.com/flathub/com.discordapp.Discord/master/com.discordapp.Discord.appdata.xml +# Disable breaking updates which will prompt users to download a deb or tar +# file and lock them out of Discord making the program unusable. Courtesy of +# NixOS contributors and the original author (@lionirdeadman), kudos to them. +Source4: https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/applications/networking/instant-messengers/discord/disable-breaking-updates.py Source99: PERMISSION ExclusiveArch: x86_64 BuildRequires: desktop-file-utils @@ -42,12 +46,13 @@ BuildRequires: update-desktop-files BuildRequires: unzip Requires: libatomic1 +Requires(post): python3-base Conflicts: discord #Patent free ffmpeg config #Snippets from https://github.com/orionhealth/electron-packager-plugin-non-proprietary-codecs-ffmpeg/blob/master/src/downloadFFMPEG.js -%define electronVersion 13.6.6 +%define electronVersion 24.1.3 %define ffmpegarch x64 %define ffmpegplatform linux %define ffmpegFileName ffmpeg-v%{electronVersion}-%{ffmpegplatform}-%{ffmpegarch}.zip @@ -103,12 +108,23 @@ mkdir -p %{buildroot}%{_bindir} ln -s %{_libdir}/%{name}/Discord %{buildroot}%{_bindir}/%{name} +# disable-breaking-updates.py script +install -v -m 644 %{SOURCE4} %{buildroot}%{_libdir}/%{name}/ +sed -i -e '/@pythonInterpreter@/d' \ + -e 's,@configDirName@,discord,' \ + -e '/print("\[Nix]/ s/Nix/Discord/' \ + %{buildroot}%{_libdir}/%{name}/disable-breaking-updates.py + %post %if 0%{?suse_version} < 1500 %desktop_database_post %endif chmod 0755 %{_libdir}/%{name}/Discord +if command -v python3 > /dev/null; then + python3 %{_libdir}/%{name}/disable-breaking-updates.py +fi + %if 0%{?suse_version} < 1500 %postun %desktop_database_postun ++++++ com.discordapp.Discord.appdata.xml ++++++ --- /var/tmp/diff_new_pack.QFam5Q/_old 2023-05-04 17:08:45.251725475 +0200 +++ /var/tmp/diff_new_pack.QFam5Q/_new 2023-05-04 17:08:45.251725475 +0200 @@ -54,6 +54,8 @@ <category>Network</category> </categories> <releases> + <release version="0.0.27" date="2023-04-26"/> + <release version="0.0.26" date="2023-03-30"/> <release version="0.0.25" date="2023-02-13"/> <release version="0.0.24" date="2023-01-14"/> <release version="0.0.23" date="2023-01-11"/> ++++++ disable-breaking-updates.py ++++++ #!@pythonInterpreter@ # slightly tweaked from the script created by @lionirdeadman # https://github.com/flathub/com.discordapp.Discord/blob/master/disable-breaking-updates.py """ Disable breaking updates which will prompt users to download a deb or tar file and lock them out of Discord making the program unusable. This will dramatically improve the experience : 1) The maintainer doesn't need to be worried at all times of an update which will break Discord. 2) People will not be locked out of the program while the maintainer runs to update it. """ import json import os import sys from pathlib import Path XDG_CONFIG_HOME = os.environ.get("XDG_CONFIG_HOME") or os.path.join( os.path.expanduser("~"), ".config" ) settings_path = Path(f"{XDG_CONFIG_HOME}/@configDirName@/settings.json") settings_path_temp = Path(f"{XDG_CONFIG_HOME}/@configDirName@/settings.json.tmp") if os.path.exists(settings_path): with settings_path.open(encoding="utf-8") as settings_file: try: settings = json.load(settings_file) except json.JSONDecodeError: print("[Nix] settings.json is malformed, letting Discord fix itself") sys.exit(0) else: settings = {} if settings.get("SKIP_HOST_UPDATE"): print("[Nix] Disabling updates already done") else: skip_host_update = {"SKIP_HOST_UPDATE": True} settings.update(skip_host_update) os.makedirs(os.path.dirname(settings_path), exist_ok=True) with settings_path_temp.open("w", encoding="utf-8") as settings_file_temp: json.dump(settings, settings_file_temp, indent=2) settings_path_temp.rename(settings_path) print("[Nix] Disabled updates") ++++++ discord-0.0.26.tar.gz -> discord-0.0.27.tar.gz ++++++ /work/SRC/openSUSE:Factory:NonFree/discord/discord-0.0.26.tar.gz /work/SRC/openSUSE:Factory:NonFree/.discord.new.1533/discord-0.0.27.tar.gz differ: char 5, line 1