Xfce Forum

Sub domains
 

You are not logged in.

#1 2021-06-02 14:23:51

KitchM
Member
Registered: 2009-08-15
Posts: 282

About Application Autostart

Under Settings Manager>Session and Startup>Application Autostart there are many items on my system.  However, only particular ones are able to be edited or removed.  Why is that?  What makes the difference?

Thanks.

Offline

#2 2021-06-02 16:45:18

alcornoqui
Member
Registered: 2014-07-28
Posts: 829

Re: About Application Autostart

I think it's related to permissions. From the Session and Startup > Application Autostart documentation:

This list contains applications that can be started automatically based on certain triggers, e.g. session start, logout etc. You can add or remove applications. Furthermore all applications that have their desktop files stored in a user-writable location can be edited.

Offline

#3 2021-06-02 17:02:30

KitchM
Member
Registered: 2009-08-15
Posts: 282

Re: About Application Autostart

That is an interesting possibility.  Maybe someone here can confirm that.

But let us suppose that to be correct.  Why then would there not be a way to reach root permissions with a sudo-like command built-in to handle such needs, ala Synaptic?

Offline

#4 2021-06-02 22:13:57

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 9,524

Re: About Application Autostart

Can confirm.

It's interesting though. Traditionally, unix/linux has always been a multi-user system -> admin + users. Packages and configurations were installed in protected areas where admins had control and user accounts created with limited capabilities. As a comparison point, Windows started out as a user-based O/S - the computer use had full access. Only in later versions were proper admin functionality added (more or less).

This being the case, the package installs are to protected areas that the user doesn't generally have access to. Though in this case, they can still enable/disable the autostart application. An added concern about "deleting" a package-installed file is that when the package is updated, it would probably replace the file anyways, undoing your delete and no doubt causing confusion.

Windows, on the other hand, doesn't really show you system-based start up files. At least not in the Startup folder. They are hidden in registry keys and service files. So in this case, there is somewhat more transparency.

tldr; though an interesting concept, I'm not sure its the right thing to allow. You still have the capability to enable/disable the startup file, though.

Offline

#5 2021-06-03 16:19:33

KitchM
Member
Registered: 2009-08-15
Posts: 282

Re: About Application Autostart

Yes, it is all too confusing in the areas where the basic concepts break down.  In this case, we have a settings area which is arguably designed for the end user, and yet the settings cannot be changed.  This mix of permission types is sometimes handled by asking for a password to unlock the root features.  Unfortunately, Xfce missed that one.

So then there must be a manual method to edit a file, as you alluded to.  However, I do not know how to do that.

Offline

#6 2021-06-03 18:09:24

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 9,524

Re: About Application Autostart

The files themselves will be located in the /etc/xdg/autostart (may be distro dependent - look for other potential xdg directories under /etc/xdg). You would edit the content manually or delete them  from there. Note that the files may (probably will) be replaced when the package that contained them is updated.

Offline

#7 2021-06-03 22:16:25

KitchM
Member
Registered: 2009-08-15
Posts: 282

Re: About Application Autostart

I found that the directory you referenced holds 38 items on my computer and that exactly matches the number of items in the Session and Startup>Application Autostart window.  Very cool.  Nice to see something simple and straight forward.

So all I have to do is delete the .desktop file that matches the item I'm concerned about, and I'm good to go.  Sadly they don't match in name, so a little detective work is needed.

Offline

#8 2021-06-03 22:30:30

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 9,524

Re: About Application Autostart

KitchM wrote:

So all I have to do is delete the .desktop file that matches the item I'm concerned about, and I'm good to go.  Sadly they don't match in name, so a little detective work is needed.

Just keep in mind that they will probably get re-added when the package that contains them is updated.

Offline

#9 2022-08-26 17:47:20

KitchM
Member
Registered: 2009-08-15
Posts: 282

Re: About Application Autostart

I thought I'd revisit this issue.  It turns out that uninstalling an application does not necessarily remove the autostart entry.

Here are some good ones.  I have an item which is listed as "firewall applet (firewall applet)".  I checked with the package manager and neither it nor firewalld is installed.  But I could delete it in the app.

I also checked on wicd, but it is not installed and not available since the latest Debian upgrade.  I had to delete the file /etc/xdg/autostart/wicd-tray.desktop.

In the same directory, I had to edit org.gnome.Evolution-alarm-notify.desktop and uncomment

OnlyShowIn=GNOME;Unity;XFCE;Dawati;MATE;

and add

NotShowIn=GNOME;XFCE;

to get rid of the evolution alarm entry.  It could not be edited and it was not installed.

The documentation states this:

${XDG_CONFIG_DIRS}/autostart/
    This is the location where the list of applications that should be automatically run on login is stored. Each autostarted application is represented by a .desktop file (see the Desktop Entry Specification for details).
    Prior to Xfce 4.3, the list of autostarted applications was stored in ~/Desktop/Autostart, which contained scripts and symbolic links to applications. If you run xfce4-session 4.4 or above for the first time, it will automatically migrate the autostart items from the old location to the standard location and place a LOCATION-CHANGED.txt file in the old directory, that describes the location change.

I think that {XDG_CONFIG_DIRS} is not well defined.  I found the location on the last example I mentioned by a search on the 'Net.

Thanks.

Offline

#10 2022-08-26 19:16:24

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 9,524

Re: About Application Autostart

KitchM wrote:

I thought I'd revisit this issue.  It turns out that uninstalling an application does not necessarily remove the autostart entry.

If the autostart entry was placed by the installed package in /etc, then when removing the package it should also remove that entry. If this is the case, you should file a bug report with that package. If however, the autostart .desktop entry is in ~/.config/autostart, then it was placed there by you and will not be automatically removed (it will not start if the application is no longer installed) and will need to be manually removed by you.

I also checked on wicd, but it is not installed and not available since the latest Debian upgrade.  I had to delete the file /etc/xdg/autostart/wicd-tray.desktop.

It should have been removed during the upgrade when the previous package was removed.

In the same directory, I had to edit org.gnome.Evolution-alarm-notify.desktop and uncomment

OnlyShowIn=GNOME;Unity;XFCE;Dawati;MATE;

and add

NotShowIn=GNOME;XFCE;

to get rid of the evolution alarm entry.  It could not be edited and it was not installed.

I've seen a few of these as well. You can try to create a bug report for those packages, but in all likelihood they won't change anything. Basically if you don't want it to show, you should manually make the change. A recommendation though: don't edit the file in /etc/xdg/autostart (it will be replaced during the next package update and you will lose your change). Instead, copy the file to ~/.config/autostart and make the change there.

The documentation states this:

${XDG_CONFIG_DIRS}/autostart/
    This is the location where the list of applications that should be automatically run on login is stored. Each autostarted application is represented by a .desktop file (see the Desktop Entry Specification for details).
    Prior to Xfce 4.3, the list of autostarted applications was stored in ~/Desktop/Autostart, which contained scripts and symbolic links to applications. If you run xfce4-session 4.4 or above for the first time, it will automatically migrate the autostart items from the old location to the standard location and place a LOCATION-CHANGED.txt file in the old directory, that describes the location change.

This isn't totally correct. Which documentation are you referring to?

I think that {XDG_CONFIG_DIRS} is not well defined.  I found the location on the last example I mentioned by a search on the 'Net.

It is in the freedesktop.org spec but may not be properly explained in the other documentation you are referring to.

Offline

#11 2022-08-26 19:27:29

KitchM
Member
Registered: 2009-08-15
Posts: 282

Re: About Application Autostart

Thanks, ToZ.  Good information.

Here's the link to the doc:
https://docs.xfce.org/xfce/xfce4-session/advanced

I didn't know anything about ~/.config/autostart.  Let me look into that right now.

Thanks again.

Offline

#12 2022-08-26 19:32:12

KitchM
Member
Registered: 2009-08-15
Posts: 282

Re: About Application Autostart

I just checked and there is no ~/.config/autostart.

Offline

#13 2022-08-26 21:55:05

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 9,524

Re: About Application Autostart

KitchM wrote:

I just checked and there is no ~/.config/autostart.

Then you haven't needed it yet. You can create it if you want to use it. The .desktop files in there will supersede the ones in /etc/xdg.

Offline

Board footer

Powered by FluxBB