:: Re: [DNG] netman-autostart_0.1.1
Top Pagina
Delete this message
Reply to this message
Auteur: Edward Bartolo
Datum:  
Aan: aitor_czr
CC: dng
Onderwerp: Re: [DNG] netman-autostart_0.1.1
Hi Aitor,

Enjoy yourself, I am working on it. I think, I got a way of putting it
right. There are two .desktop files that control how netman gui
behaves:
a) /etc/xdg/autostart/netman.desktop
b) /usr/share/applications/netman.desktop

The netman-gui.postinst script has to modify both of them. If netman
is set not to start automatically /etc/xdg/autostart/netman.desktop
should be deleted. The sed command in the postinst script also has to
make sure no multiple Exec= and Comment= lines are added to both
.desktop files.

Edward


On 06/01/2016, aitor_czr <aitor_czr@???> wrote:
> Hi Edward, Rainer
>
> On 01/06/2016 04:58 PM, Edward Bartolo <edbarx@???> wrote:
>>> Maybe, this can shed some light on what is causing this problem. The
>>> >first time dpkg-reconfigure is used on netman-gui it doesn't exit
>>> >complaining the netman.desktop file is not found. This may mean the
>>> >netman.desktop file is being deleted by a script called by
>>> >dpkg-reconfigure, maybe, netman-gui.postinst?
>>          2) db_get netman-gui/netman-autostart
>>                  if [ "$RET" = "true" ]; then
>>                          file="/etc/xdg/autostart/netman.desktop";
>>                          mv/usr/share/applications/netman.desktop
>> /etc/xdg/autostart/
>>                  fi
>>          ;;

>>
>> This moves the /usr/share/applications/netman.desktop file to
>> /etc/xdg/autostart, consequently, /usr/share/applications/netman.desktop
>> doesn't exist anymore afterwards. And it doesn't do anything in order to
>> disable autostartf if $RET is not true. If the /etc/xdg/autostart file
>> is not supposed to be modified, I suggest creating a symlink instead, ie
>>
>> ln -s/usr/share/applications/netman.desktop /etc/xdg/autostart/
>>
>> You could also use cp instead of mv so that the autostart file will be a
>> copy of the original.
>
>
> Sorry, today i had a family meal. Yes, this is what is causing the
> "problem": if the user prefers to autostart netman automaticaly, the
> script removes the launcher from xfce-applications.menu,
> lxde-applications.menu, etc... But i can change "mv" by "cp" if you
> prefer so.
>
> Cheers,
>
>     Aitor.

>