1. Home
  2. Linux

How to automatically start programs on Mate

The Mate desktop environment has a lot of settings that users can take advantage of for customization purposes. One of the best, most in-depth customization features is the autostart function, as it allows users to automatically start programs on Mate. They can decide how their Mate system loads up programs, scripts, and even services!

Configuring the autostart function on the Mate desktop is done through the system settings. To gain access to this area of the desktop, follow the instructions below.

Autostart programs via GUI

Configuring automatic program starting in Mate with the GUI is done through the Control Center application. To access the control center, open up your menu and look for “Control Center.” Alternatively, the app can be opened by pressing Alt + F2 and writing in mate-control-center in the box.

In the Control Center application on the Mate desktop, you’ll see a whole lot of different settings. All of these settings correspond to individual aspects of the Mate desktop environment and can be changed at will.

Scroll through the Control Center application and make your way to the “Personal” section. From there, find the “Startup Applications” button and click on it to access the autostart configuration area for the Mate desktop.

Inside of the Startup Applications Preferences window, you’ll see a huge list. In this list, there are dozens of startup services, programs, scripts, etc. If you’d like to create a new, custom startup system, locate the “+ Add” button and click on it with the mouse.

After clicking on the “+ Add” button, a small pop-up box will appear. In this box, there are several text fields. The fields are “Name,” “Command,” and “Comment.”

To automatically start up a program, find the “Name” box and write out the name of the program. Then, write in the name of the program in the “Command” box.

For example, to automatically start up Firefox in Mate upon login, you’d write “firefox” in the command area.

Removing program autostart with GUI

You may wish to stop a program from automatically starting on the Mate desktop. To do this, gain access to the Control Center.

Note: for quick access to the Control Center in Mate, press Alt + F2 and write “mate-control-center” in the command box.

Once in the Control Center GUI tool in the Mate desktop, look for “Startup Applications” and click on it to gain access to the autostart GUI.

Inside of the autostart GUI, scroll through the list of startup entries and select the one you’d like to disable with the mouse. Then, check the check-box next to the service to stop it from automatically launching.

Alternatively, remove the startup entry for good by selecting the startup entry in the list with the mouse, and selecting the “- Remove” button.

Autostart programs via terminal

The Mate autostart GUI tool is a great way to manage automatic startup programs quickly. However, it’s not the only way. If you’re a terminal fan, you can also create automatic startup entries in the command-line.

To make a new startup entry, launch a terminal window with Ctrl + Alt + T or Ctrl + Shift + T. Then, move the terminal session into the /usr/share/applications/ directory.

cd /usr/share/applications/

Run the ls command and view the program shortcuts in the folder, so that you may locate the name of the program you want to auto-start.

ls

Can’t find the app you need? Combine ls with the grep tool to more easily filter out a keyword.

ls | grep programname

Take the name of the program and plug it into the following cp command to create a new autostart entry. For example, to autostart Firefox on Mate through the terminal, you’d do:

cp firefox.desktop ~/.config/autostart/

Removing automatic program start in the terminal

To get rid of an automatic startup entry for the Mate desktop environment from the command-line, you’ll need CD into the ~/.config/autostart directory.

cd ~/.config/autostart

Can’t access the ~/.config/autostart directory on your Mate desktop? If so, you may not have an autostart folder. To create one, use the mkdir command.

mkdir -p ~/.config/autostart

Inside of the autostart folder, run the ls command. Running this command will allow you to take a look inside the folder.

ls

Take note of the files revealed by the ls tool. Then, plug them into the following rm command to delete and disable the startup entries.

rm programname.desktop

Want to delete more than one startup entry at a time? Use the rm command, but instead of specifying the exact name of the startup entry file (such as firefox.desktop,) you can make use of the wildcard (*) function in Bash on Linux.

Using the wildcard (*) will allow you to automatically remove and delete all desktop shortcut files from the ~/.config/autostart directory.

rm *.desktop

Leave a comment