Skip to content

Instantly share code, notes, and snippets.

@m-triassi
Last active November 25, 2024 20:58
Show Gist options
  • Save m-triassi/74454d8550956e3152b0b3d1488676f7 to your computer and use it in GitHub Desktop.
Save m-triassi/74454d8550956e3152b0b3d1488676f7 to your computer and use it in GitHub Desktop.
A simple script to update discord on debian based distributions, like Ubuntu, via discord's API. Put this in a directory on your $PATH.
#!/usr/bin/env bash
if [[ $1 == "-h" ]]; then
echo "Usage: update-discord [-c]"
echo " -h: Display this help message"
echo " -c: Clean up after install"
exit 0
fi
wget https://discordapp.com/api/download?platform=linux -O ~/Downloads/discord.deb
sudo apt install ~/Downloads/discord.deb
if [[ $1 == "-c" ]]; then
rm ~/Downloads/discord.deb
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment