GNU bug report logs - #72714
[PATCH] home: services: Add 'home-sway-service-type'.

Previous Next

Package: guix-patches;

Reported by: Arnaud Daby-Seesaram <ds-ac <at> nanein.fr>

Date: Mon, 19 Aug 2024 15:33:02 UTC

Severity: normal

Tags: patch

Done: "pelzflorian (Florian Pelz)" <pelzflorian <at> pelzflorian.de>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: "pelzflorian (Florian Pelz)" <pelzflorian <at> pelzflorian.de>
To: Arnaud Daby-Seesaram <ds-ac <at> nanein.fr>
Cc: 72714 <at> debbugs.gnu.org
Subject: [bug#72714] [PATCH v4] home: services: Add 'home-sway-service-type'.
Date: Sat, 14 Sep 2024 15:28:42 +0200
Thank you Arnaud for this well-written home-sway-service!

Some comments for you or the one who pushes your patch.  I would
rather not take any responsibility for sway myself.

> @quotation Note
> This home service only sets up configuration file and profile packages

Typo: Please add 'the': sets up the configuration file and profile packages

> The function @code{sway-configuration->file} defined below can be used
> to provide the value for the @code{sway-configuration} field of
> @code{greetd-wlgreet-sway-session}.

Good.  Even though it is a little strange that one would add a home
module (gnu home services sway) to the operating-system configuration,
I know no better place for this `sway-configuration->file' procedure,
since the record is for Guix Home and being able to use it for greetd
is just an extra feature.


> @lisp
> (define bg-file
>   (computed-file
>    "background.png"
>    #~(let* ((insvg (string-append
>                     #$guix-backgrounds
>                     "/share/backgrounds/guix/guix-checkered-16-9.svg"))
>             (out #$output)
>             (cmd (string-append
>                   #$librsvg "/bin/rsvg-convert " insvg " -o " out)))
>        (system cmd))))
> 
> (service home-sway-service-type
>          (sway-configuration
>           (gestures
>            '((swipe:3:down . "move to scratchpad")
>              (swipe:3:up   . "scratchpad show")))
>           (outputs
>            (list (sway-output
>                   (identifier '*)
>                   (bg bg-file))))))
> @end lisp

Why not (bg #~(file-append #$guix-backgrounds
                     "\
/share/backgrounds/guix/guix-checkered-16-9.svg"))
?  This does not work right now, but could you change bg and
perhaps status-command to accept gexps?


> swiping down (resp.@ up) with three fingers moves the active window to
> the scratchpad (resp.@ shows/hides the scratchpad).

Should be with a colon: resp.@: up

You should run untabify on all of  gnu/home/services/sway.scm
to get rid of nasty tabs.

Otherwise looks really good to me (although I have not cross-checked
the man pages).

Regards,
Florian




This bug report was last modified 219 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.