How are programs executed in Ubuntu?

Colin Law clanlaw at gmail.com
Tue Feb 2 12:35:38 UTC 2016


On 2 February 2016 at 11:49, blind Pete <0123peter at gmail.com> wrote:
> Colin Law wrote:
>
>> On 2 February 2016 at 03:12, blind Pete <0123peter at gmail.com> wrote:
>>> Colin Law wrote:
>>>
>>>> On 29 January 2016 at 21:00, Jim Byrnes <jf_byrnes at comcast.net> wrote:
>>>>> ...
>>>>> After much stumbling around I finally got this to work. The first thing
>>>>> I did wrong was to create a file called myprog.desktop based on the
>>>>> link you gave above and drop it in /local/share/applications. That did
>>>>> not work.
>>>>>
>>>>> Then I tried using the utilities mentioned in the link above, but they
>>>>> could
>>>>> not find the file even I was looking at it in Nemo.  Finally I used ls
>>>>> in a terminal and it showed up as myprog.desktop.desktop. Apparently
>>>>> that location adds .desktop by default but Nemo did not display it.
>>>>>
>>>>> Once I fixed that the desktop utilities put it in the proper location
>>>>> and I was able to put it on the launcher.
>>>>
>>>> Just checking that you realise that the proper place is
>>>> .local/share/applications.  Installed applications put their launchers
>>>> in /usr/share/applications but generally you should put diy ones in
>>>> .local/share/applications.
>>>>
>>>> Colin
>>>
>>> For a single user machine, put your personal configurations in
>>> ~/.local/share/applications and leave /usr/share/applications
>>> to Ubuntu.
>>>
>>> For a multi user machine the system administrator might put things in
>>> /usr/local/share/applications.  Stuff in /usr/local/ is available to
>>> all users and should not be overwritten by Ubuntu even during a
>>> re-install, *if* you put /usr/local/ on its own partition.
>>
>> Does the Dash automatically pick up desktop files from
>> /usr/local/share/applications?
>>
>> Colin
>
> I don't know.  Put one there and see what happens.

When you said that administrators might put desktop files there then I
assumed you knew that was a valid place to put them.  Having tried it
it appears that /usr/local/share/applications is not an appropriate
place for desktop files, so unless I have missed something, which is
quite possible, then in order to add system wide desktop files they
have to go in /usr/share/applications.

Colin




More information about the ubuntu-users mailing list