back
Written 2022-10-26
Updated on 2024-07-29
Discord updates can be annoying, especially if you're not on Windows or a Debian-based Linux distribution. This is because Discord ships their own .deb
files and is not distributed through a repository.
Arch Linux, on the other hand, distributes Discord through its community
repository. When an update rolls around, though, usually it takes a while for the package maintainer to push an update. For platforms like this, Discord shows a "helpful" message, leaving users to figure it out on their own.
Fortunately though, there's a solution.
This method allows you to trick the Discord executable into thinking it's been updated. First, check for the path of the discord
executable:
file $(which discord)
# Output - /sbin/discord: symbolic link to /opt/discord/Discord
Then, cd
to the directory it gave you. In my case it's /opt/discord
.
Now, edit resources/build_info.json
with your favorite text editor. It should look like this:
{
"releaseChannel": "stable",
"version": "0.0.xx"
}
Update the version
field to the current version of Discord (0.0.61 as of July 29th, 2024).
PKGBUILD
wayMake sure you know how to build and install AUR packages before using this method.
If you don't like editing configuration files to update things, you can also download the package's PKGBUILD
and build the package yourself. This involves using the Arch Build System. This method is also useful if you want to build the package on one machine and transfer it to another machine.
To get started, install the devtools
package:
sudo pacman -S devtools
This will add the pkgctl
command to your system, which will let you download PKGBUILD
files from the Arch Linux repositories.
Now, export the current PKGBUILD
for the discord
package:
pkgctl repo clone --protocol=https discord
This will create a discord
directory inside your working directory. Enter this directory and you will see a PKGBUILD. It should look something like this (some contents omitted):
pkgname=discord
_pkgname=Discord
pkgver=0.0.xx
pkgrel=1
pkgdesc="All-in-one voice and text chat for gamers"
# ...
prepare() {
# ...
}
package() {
# ...
}
Update the pkgver
field to the current version of Discord (0.0.61 as of July 29th, 2024). Then, build the package as you would build an AUR package:
makepkg -si
Now, the updated package should be installed. Simply repeat this process every time you get the update message.
Open the launcher. Discord should now install updates and launch as normal. Enjoy!
Once the updated version is finally pushed to the repository, you should be able to update with pacman -Syu
as normal, and your system should switch to the version from the repository (unless you used the PKGBUILD
method, in which case pacman will treat your custom built version and the version in the repository as the same).
As always, if you have any questions, feel free to contact me!