Is there a way to prompt users to connect a non-auto-connect interface during installation?

Aaron Hampton aaron.hampt at gmail.com
Tue Feb 14 03:51:54 UTC 2017


Is it possible to check which interfaces a snap is connected to from within
the snap? Or, would I have to try accessing the resources an interface
exposes to know whether or not it had access?

I tried calling snap interfaces from within my program, but I got a
permissions error.

On Feb 13, 2017 1:50 AM, "Alberto Mardegan" <alberto.mardegan at canonical.com>
wrote:

> On 12/02/2017 12:30, Aaron Hampton wrote:
> > Hi,
> >
> > I am working on snapping a desktop application that needs access to
> > hardware-observe. Is there a way to prompt the user to connect the
> > interface during the installation of the snap? Or is the only way to
> > have the user run snap connect?
>
> While this feature is missing, you could wrap your programs in a shell
> script that checks whether the needed permissions are there and, if not,
> print a message using zenity to inform the user.
>
> Ciao,
>   Alberto
>
>
> --
> Snapcraft mailing list
> Snapcraft at lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/snapcraft/attachments/20170213/2ab479de/attachment.html>


More information about the Snapcraft mailing list