Skip to content

Instantly share code, notes, and snippets.

@chayanforyou
Created August 20, 2022 06:26
Show Gist options
  • Save chayanforyou/33b60cd130dd357095f9073d6a018445 to your computer and use it in GitHub Desktop.
Save chayanforyou/33b60cd130dd357095f9073d6a018445 to your computer and use it in GitHub Desktop.
Make Discord auto start on Ubuntu 20.04 & 22.04

The Discord app on linux ubuntu desktop does not start the app. But you can make it auto start by following this steps.

  • Open Applications and search for Startup Applications

  • Then click Add an input box will open, put the following information and Save.
    Name: Discord
    Command: /usr/bin/discord --tray
    

Now when you power on your PC the Discord app will open automecally on startup.

@buithehoa
Copy link

buithehoa commented Jan 8, 2024

Hi, You can also just create a symlink of the .desktop file in ~/.config/autostart which is more accurate. The .desktop file position will change depending on the installation (flatpak, snap, .deb, ...), the possible lookup folders are references in $XDG_DATA_DIRS

So, a one liner to run in the terminal is:

ln -s "$(find $(echo $XDG_DATA_DIRS | tr ':' ' ') -iname '*discord*.desktop' 2>/dev/null | head -n 1)" ~/.config/autostart

This is a much better solution. Thank you, @divad1196

@MohammedZ666
Copy link

MohammedZ666 commented Feb 19, 2024

The above cmd didn't minimize the client, this did for me:
discord --start-minimized

@ElectronicLED
Copy link

Thanks man!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment