Subject: Re: bug#48796: Guix on Debian 11 - Cant run or find applications from Guix

From: zimoun <[email-masked]>
Date: Mon, 23 Aug 2021 12:42:15 +0200

Hi,

On Thu, 15 Jul 2021 at 13:09, bo0od <[email-masked]> wrote:
>> Does this message [1] fix your issue?
>
> "If you type "source ~/.guix-profile/etc/profile" from a Bash shell, it loads
> the needed environment variable"
>
> yes it worked, but thats not really what im asking as this is workaround for
> the issue but im asking for a solution to the users as they can type the app
> name and it should run and icon should be shown somewhere on application menu
> or desktop or so.
>
> flatpak , snap which work almost similarly to guix can do that then guix
> should do that as well.

I have never used Flatpack but from the doc, I read:

--8<---------------cut here---------------start------------->8---
$ flatpak run org.gimp.GIMP
--8<---------------cut here---------------end--------------->8---

<https://docs.flatpak.org/en/latest/using-flatpak.html#running-applications>

Then reading:

<https://docs.flatpak.org/en/latest/desktop-integration.html>
<https://docs.flatpak.org/en/latest/conventions.html>

I am not convinced that Guix should follow the Flatpack approach by
default.  And somehow, it is not what “guix pack” already does. ;-)

About Snap, I have not been able to get the right doc.

> otherwise guix should mention that there wont be icons nor ability to run the
> applications from terminal unless you do 1 2 3 after guix app installaion
> which is sadly a downside for new comers.

As Mark explained,

        In order to set your environment variables appropriately for
        your entire desktop environment, you must arrange for the
        environment variable settings to be loaded before the desktop
        session is launched.  I don't remember off-hand how to do this
        in Debian.  I seem to recall that one approach is to create an
        ~/.xsessionrc file, which should be an executable Bash script
        that loads the needed environment variable settings and then
        launches the desktop environment.  Maybe there's a better way.

        I'm surprised this isn't well-trodden territory, long ago documented in
        our manual, but I guess it isn't.  It would be good if some Debian
        expert(s), or at least someone who runs Guix on top of Debian, would
        step forward to fill in the details.

it is possible to have the icons and run them from the desktop
launcher.  The configuration has to be done manually though.

Therefore, a section should be added to the manual under «Application
Setup», IMHO.

All the best,
simon