Re: [qubes-users] Adding appmenu entries to AppVM's

2017-07-05 Thread lokedhs
On Thursday, 6 July 2017 06:21:01 UTC+8, Unman  wrote:
> On Wed, Jul 05, 2017 at 09:20:48PM +, js...@riseup.net wrote:
> > loke...@gmail.com:
> > > I have some applications I have installed manually in /usr/local on 
> > > appvms. I would like to create appmenu entries for these applications. 
> > > However, the Qubes appmenu management only deals with menus coming from 
> > > templates.
> > > 
> > > Is there an official way to handle this?
> > 
> > I don't think there's an "official" way to do it, but it is possible.
> > 
> > I made a few custom appmenu entries by creating a new .desktop file in
> > /usr/share/applications/ in the *template* on which the appvm is based.
> > You'll never launch it in the template, but you have to create the
> > .desktop file there so Qubes will recognize it.
> > 
> > Then create a new .desktop file in
> > /var/lib/qubes/vm-templates//apps.templates/ in dom0 pointing
> > to the .desktop file you created in the template.
> > 
> > If that's not enough it might also be necessary to create another
> > .desktop file in /var/lib/qubes/appvms//apps/ in dom0 for it as well.
> > 
> > This will result in it being possible to add your new entry for any
> > appvm based on that template, not just the one you installed the
> > application on, but it should get the job done.
> 
> There's another way which is somewhat simpler, and which fits your
> scenario somewhat better.
> BUT , if you create a custom entry in an AppVM menu it will get
> overwritten when qvm-sync-menus is called (e.g template update, add new
> shortcuts etc.) You can work round this by making a custom menu
> containing custom menu entries - I do this on setup, because in my
> experience naive users dont need to know about the underlying VM
> structures to work efficiently in Qubes.
> 
> Remember that you can use qvm-run in dom0 to launch applications in
> appVMs. So you can create a simple .desktop file which will run the
> command in the required qube. If you look at the desktop files in
> /var/lib/qubes/appvms/XXX/apps/ you can see the structure.
> Those files tend to use qubes-desktop-run but you can call the
> application directly in many cases. (HINT - open a terminal in the qube
> and find out what command you need to run to start the application. Then
> try that command in dom0 using qvm-run. THEN create a desktop file
> using that command.)
> 
> Then just write a custom menu entry calling that desktop file.
> 
>   My menu
> 
>   custom.desktop
> 
> 

Thank you.

Yours, and the template-based method mentioned in the previous reply both work, 
but neither of them are ideal. I haven't decided which method to go for yet.

In my opinion, qvm-sync-menus should take the entries in /usr/local in the 
appvms into consideration as well. I haven't looked at how it's implemented but 
it seems like something that shouldn't be too difficult to implement?

-- 
You received this message because you are subscribed to the Google Groups 
"qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to qubes-users+unsubscr...@googlegroups.com.
To post to this group, send email to qubes-users@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/qubes-users/48acae2b-e094-4285-a4d3-f3ed8f0aaae3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [qubes-users] Adding appmenu entries to AppVM's

2017-07-05 Thread Unman
On Wed, Jul 05, 2017 at 09:20:48PM +, js...@riseup.net wrote:
> loke...@gmail.com:
> > I have some applications I have installed manually in /usr/local on appvms. 
> > I would like to create appmenu entries for these applications. However, the 
> > Qubes appmenu management only deals with menus coming from templates.
> > 
> > Is there an official way to handle this?
> 
> I don't think there's an "official" way to do it, but it is possible.
> 
> I made a few custom appmenu entries by creating a new .desktop file in
> /usr/share/applications/ in the *template* on which the appvm is based.
> You'll never launch it in the template, but you have to create the
> .desktop file there so Qubes will recognize it.
> 
> Then create a new .desktop file in
> /var/lib/qubes/vm-templates//apps.templates/ in dom0 pointing
> to the .desktop file you created in the template.
> 
> If that's not enough it might also be necessary to create another
> .desktop file in /var/lib/qubes/appvms//apps/ in dom0 for it as well.
> 
> This will result in it being possible to add your new entry for any
> appvm based on that template, not just the one you installed the
> application on, but it should get the job done.

There's another way which is somewhat simpler, and which fits your
scenario somewhat better.
BUT , if you create a custom entry in an AppVM menu it will get
overwritten when qvm-sync-menus is called (e.g template update, add new
shortcuts etc.) You can work round this by making a custom menu
containing custom menu entries - I do this on setup, because in my
experience naive users dont need to know about the underlying VM
structures to work efficiently in Qubes.

Remember that you can use qvm-run in dom0 to launch applications in
appVMs. So you can create a simple .desktop file which will run the
command in the required qube. If you look at the desktop files in
/var/lib/qubes/appvms/XXX/apps/ you can see the structure.
Those files tend to use qubes-desktop-run but you can call the
application directly in many cases. (HINT - open a terminal in the qube
and find out what command you need to run to start the application. Then
try that command in dom0 using qvm-run. THEN create a desktop file
using that command.)

Then just write a custom menu entry calling that desktop file.

My menu

custom.desktop







-- 
You received this message because you are subscribed to the Google Groups 
"qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to qubes-users+unsubscr...@googlegroups.com.
To post to this group, send email to qubes-users@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/qubes-users/20170705222058.bosrri25v425syel%40thirdeyesecurity.org.
For more options, visit https://groups.google.com/d/optout.


Re: [qubes-users] Adding appmenu entries to AppVM's

2017-07-05 Thread js...@riseup.net
loke...@gmail.com:
> I have some applications I have installed manually in /usr/local on appvms. I 
> would like to create appmenu entries for these applications. However, the 
> Qubes appmenu management only deals with menus coming from templates.
> 
> Is there an official way to handle this?

I don't think there's an "official" way to do it, but it is possible.

I made a few custom appmenu entries by creating a new .desktop file in
/usr/share/applications/ in the *template* on which the appvm is based.
You'll never launch it in the template, but you have to create the
.desktop file there so Qubes will recognize it.

Then create a new .desktop file in
/var/lib/qubes/vm-templates//apps.templates/ in dom0 pointing
to the .desktop file you created in the template.

If that's not enough it might also be necessary to create another
.desktop file in /var/lib/qubes/appvms//apps/ in dom0 for it as well.

This will result in it being possible to add your new entry for any
appvm based on that template, not just the one you installed the
application on, but it should get the job done.

-- 
You received this message because you are subscribed to the Google Groups 
"qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to qubes-users+unsubscr...@googlegroups.com.
To post to this group, send email to qubes-users@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/qubes-users/8335b854-17e7-d8c2-175b-578d6304fa15%40riseup.net.
For more options, visit https://groups.google.com/d/optout.


[qubes-users] Adding appmenu entries to AppVM's

2017-07-05 Thread lokedhs
I have some applications I have installed manually in /usr/local on appvms. I 
would like to create appmenu entries for these applications. However, the Qubes 
appmenu management only deals with menus coming from templates.

Is there an official way to handle this?

-- 
You received this message because you are subscribed to the Google Groups 
"qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to qubes-users+unsubscr...@googlegroups.com.
To post to this group, send email to qubes-users@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/qubes-users/ce5ba6ac-1f0c-42ff-b320-7e903d6270d1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.