From unknown Fri Sep 19 14:23:35 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#77352] [PATCH] home: services: define hyprland home service Resent-From: Carmine Margiotta Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 29 Mar 2025 06:22:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 77352 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 77352@debbugs.gnu.org Cc: Carmine Margiotta X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.174322927012599 (code B ref -1); Sat, 29 Mar 2025 06:22:02 +0000 Received: (at submit) by debbugs.gnu.org; 29 Mar 2025 06:21:10 +0000 Received: from localhost ([127.0.0.1]:56430 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tyPZ7-0003H6-88 for submit@debbugs.gnu.org; Sat, 29 Mar 2025 02:21:10 -0400 Received: from lists.gnu.org ([2001:470:142::17]:55278) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tyJ5E-0000pz-Cc for submit@debbugs.gnu.org; Fri, 28 Mar 2025 19:25:53 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tyJ59-0007a6-1W for guix-patches@gnu.org; Fri, 28 Mar 2025 19:25:47 -0400 Received: from out-02.smtp.spacemail.com ([63.250.43.87]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tyJ56-0007jn-7E for guix-patches@gnu.org; Fri, 28 Mar 2025 19:25:46 -0400 Received: from prod-lbout-phx.jellyfish.systems (unknown [198.177.122.3]) by smtp.spacemail.com (Postfix) with ESMTPA id 4ZPc8N0Ty4zGp4h; Fri, 28 Mar 2025 23:25:40 +0000 (UTC) Received: from localhost.localdomain (unknown [81.56.0.160]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mail.spacemail.com (Postfix) with ESMTPSA id 4ZPc8M1KNBz6tkM; Fri, 28 Mar 2025 23:25:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cmargiotta.net; s=spacemail; t=1743204339; bh=x6yfU4GDJkSZiQzkyfRAw8mAGMxs+DnY470lKXze37Q=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=XphTa53VQqrGT2QF5if8fSZ83Cz9lcr/LCveIcBvIsVEtSIbdKefUt9Lh68lQB7p7 /nOa1LuVhh6XOHhvxIi4eB6cBoXbezN6y3i3vIiL0pVh9mXXTZzptBASD/FUkoEO35 FQ5lNAVp8zRw3BBm/i1HUaD0Hwu91iQHIjy/baen19bx71V23mGUoNpLN7U26f9ctl JEjeu1/2e6rDzxvxtBnY+RHZ6D3q3sceVi7jzVKiolaRieM8h70e06jJ8ZlbzvGBu9 0FBbpb4AHU7sFQ3dAV9FZ55Qj7kkwM2WqRu7MEA5QdU9WLguMI5ezx/jMt5n1Co6Yg AJuBQruxQmQBA== From: Carmine Margiotta Date: Sat, 29 Mar 2025 00:25:03 +0100 Message-ID: <20250328232510.32282-2-email@cmargiotta.net> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20250328232510.32282-1-email@cmargiotta.net> References: <20250328232510.32282-1-email@cmargiotta.net> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=63.250.43.87; envelope-from=email@cmargiotta.net; helo=out-02.smtp.spacemail.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 1.0 (+) X-Mailman-Approved-At: Sat, 29 Mar 2025 02:21:01 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) --- gnu/home/services/hyprland.scm | 490 +++++++++++++++++++++++++++++++++ 1 file changed, 490 insertions(+) create mode 100644 gnu/home/services/hyprland.scm diff --git a/gnu/home/services/hyprland.scm b/gnu/home/services/hyprland.scm new file mode 100644 index 0000000000..f024f272d7 --- /dev/null +++ b/gnu/home/services/hyprland.scm @@ -0,0 +1,490 @@ +;;; GNU Guix --- Functional package management for GNU +;;; Copyright © 2025 Carmine Margiotta +;;; +;;; This file is part of GNU Guix. +;;; +;;; GNU Guix is free software; you can redistribute it and/or modify it +;;; under the terms of the GNU General Public License as published by +;;; the Free Software Foundation; either version 3 of the License, or (at +;;; your option) any later version. +;;; +;;; GNU Guix is distributed in the hope that it will be useful, but +;;; WITHOUT ANY WARRANTY; without even the implied warranty of +;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;;; GNU General Public License for more details. +;;; +;;; You should have received a copy of the GNU General Public License +;;; along with GNU Guix. If not, see . + +(define-module (gnu home services hyprland) + #:use-module (gnu packages wm) + #:use-module (guix gexp) + #:use-module (gnu services configuration) + #:use-module (gnu home services) + #:use-module (guix packages) + #:use-module (ice-9 match) + #:use-module (srfi srfi-1) + + #:export (hyprland-extension hyprland-configuration binding monitor + home-hyprland-service-type)) + +;;; Commentary: +;;; +;;; A Guix Home service to configure Hyprland, an highly customizabile dynamic tiling Wayland compositor +;;; +;;; Code: + +;;; +;;; Helper functions. +;;; + +;; Repeat v n times +(define (repeat v n) + (if (eq? n 0) + '() + `(,v ,@(repeat v + (- n 1))))) + +;; Generate an indenter string of n tabs +(define (indent tabs) + (if (<= tabs 0) "" + (apply string-append + (repeat "\t" tabs)))) + +(define (flatten lst) + (let loop + ((lst lst) + (acc '())) + (cond + ((null? lst) + acc) + ((pair? lst) + (loop (car lst) + (loop (cdr lst) acc))) + (else (cons lst acc))))) + +;;; +;;; Definition of configurations. +;;; + +;; Entry inside a 'block' configuration +;; allowed formats: (symbol string) (symbol number) (symbol boolean) (symbol block-entries) +;; A block entry can contain a list of block entries, effectively allowing nested blocks +(define (block-entry? data) + (or (null? data) + (match data + (((? symbol?) + (or (? string?) + (? number?) + (? boolean?) + (? block-entries?))) + #t)))) + +;; List of block entries +(define (block-entries? data) + (every block-entry? data)) + +;; An executable (a target for the exec action) can be a string or a gexp +(define (executable? value) + (or (string? value) + (gexp? value))) + +;; A list of valid executables +(define (executable-list? values) + (every executable? values)) + +;; Block sub-configuration (a container of block entries) +(define-configuration block + (entries (block-entries '()) "Block entries" + (serializer (lambda (name value) + (serialize-block-entries name value 1))))) + +;; Monitor sub-configuration +(define-configuration monitor + (name (string "") "Monitor's name" + (serializer (lambda (_ n) + (string-append "monitor = " n ", ")))) + (resolution (string "preferred") "Monitor's resolution" + (serializer (lambda (_ n) + (string-append n ", ")))) + (position (string "auto") "Monitor's position" + (serializer (lambda (_ n) + (string-append n ", ")))) + (scale (string "1") "Monitor's scale" + (serializer (lambda (_ n) + n))) + (transform (string "") "Monitor's scale" + (serializer (lambda (_ n) + (if (string-null? n) "\n" + (string-append ", transform, " n "\n")))))) + +;; List of monitors definition +(define (monitors? arg) + (every monitor? arg)) + +;; List of strings +(define (string-list? arg) + (every string? arg)) + +;; Binding sub-configuration +(define-configuration binding + (flags (string "") + "Bind flags (https://wiki.hyprland.org/Configuring/Binds/)" + (serializer (lambda (_ n) + (string-append "bind" n " = ")))) + (mod (string "$mod") "Mod key" + (serializer (lambda (_ n) + n))) + (shift? (boolean #f) "If mod is shifted" + (serializer (lambda (_ n) + (string-append (if n " SHIFT" "") ", ")))) + (key (string) "Binding main key" + (serializer (lambda (_ n) + (string-append n ", ")))) + (action (string "exec") "Binding action" + (serializer (lambda (_ n) + n))) + (args (executable "") "Binding action's args" + (serializer (lambda (name value) + (if (string? value) + (if (string-null? value) "\n" + (string-append ", " value "\n")) + #~(string-append ", " + #$(serialize-executable name value) + "\n")))))) + +;; List of bindings +(define (binding-list? value) + (every binding? value)) + +;; Optional string +(define-maybe/no-serialization string) + +;; Binding block sub-configuration +(define-configuration bindings + (main-mod (maybe-string "") "Main mod bound to $mod" + (serializer (lambda (_ n) + (string-append "\n$mod = " n "\n\n")))) + (binds (binding-list '()) "Bindings" + (serializer (lambda (_ n) + #~(string-append #$@(map (lambda (b) + (serialize-configuration b + binding-fields)) n)))))) + +;;; +;;; Serialization functions. +;;; + +(define (serialize-block name block) + #~(string-append #$(symbol->string name) " {\n" + #$(if (null? block) "" + (serialize-configuration block block-fields)) "\n}\n")) + +;; A block entry will be serialized as an indented hyprlang +;; statement, nested blocks are allowed +(define (serialize-block-entry value tabs) + (string-append (or (match value + (() "") + (((? symbol? name) + value) + (string-append (indent tabs) + (symbol->string name) + (match value + ((? string? v) + (string-append " = " v)) + ((? number? v) + (string-append " = " + (number->string v))) + ((? boolean? v) + (if v " = true" " = false")) + ((? block-entries? v) + (string-append " {\n" + (serialize-block-entries + #f v + (+ tabs 1)) + (indent tabs) "}"))) + "\n")) + ((_) + #f)) "\n"))) + +;; String lists will be serialized as name = value\n +(define (serialize-string-list name values) + (apply string-append + (map (lambda (w) + (string-append (symbol->string name) " = " w "\n")) values))) + +;; Gexp executables will be serialized on a program-file +(define (serialize-executable name value) + (if (string? value) value + (program-file (symbol->string name) value + #:module-path %load-path))) + +;; Lists serializers +(define (serialize-block-entries _ entries level) + (apply string-append + (map (lambda (e) + (serialize-block-entry e level)) entries))) + +(define (serialize-monitors _ monitors) + #~(string-append #$@(map (lambda (m) + (serialize-configuration m monitor-fields)) + monitors))) + +(define (serialize-executable-list name values) + #~(apply string-append + (map (lambda (w) + (string-append #$(symbol->string name) " = " w "\n")) + '#$(map (lambda (v) + (serialize-executable name v)) values)))) + +;; Hyprland full configuration +(define-configuration hyprland-configuration + (package + (package + hyprland) "Hyprland package to use" + (serializer (λ (_ n) ""))) + (monitors (monitors (list (monitor))) "Monitors definition") + (exec-once (executable-list '()) "Command to exec once") + (exec (executable-list '()) "Command to automatically exec") + (general (block (block)) "General configuration variables") + (decoration (block (block)) "Decoration configuration variables") + (animations (block (block)) "Animation configuration variables") + (workspace (string-list '()) "Workspaces settings") + (windowrule (string-list '()) "Window rules (v2)") + (dwindle (block (block)) "Dwindle layout settings") + (master (block (block)) "Master layout settings") + (misc (block (block)) "Misc settings") + (input (block (block)) "Input settings") + (gestures (block (block)) "Gestures settings") + (bindings (bindings (bindings)) "Bindings configuration" + (serializer (λ (_ n) + (serialize-configuration n bindings-fields)))) + (extra-config (string "") "Extra config" + (serializer (λ (_ n) + (string-append n "\n"))))) + +;; Hyprland configuration extension for other services +;; External services can add new exec entries or new bindings +(define-configuration hyprland-extension + (exec-once (executable-list '()) + "Commands to be executed with hyprland once") + (exec (executable-list '()) "Commands to be executed with hyprland") + (bindings (binding-list '()) "Extra binds") + (no-serialization)) + +;;; +;;; Default settings and useful constants. +;;; +(define-public %default-hyprland-general + (block (entries '((gaps_in 5) + (gaps_out 20) + (border_size 2) + (col.active_border "rgba(33ccffee) rgba(00ff99ee) 45deg") + (col.inactive_border "rgba(595959aa)") + (resize_on_border #f) + (allow_tearing #f) + (layout "dwindle"))))) + +(define-public %default-hyprland-decoration + (block (entries '((rounding 10) + (rounding_power 2) + (active_opacity 1.0) + (inactive_opacity 0.9) + (dim_inactive #t) + (dim_strength 0.05) + + (shadow ((enabled #t) + (range 4) + (render_power 3) + (color "rgba(1a1a1aee)"))) + (blur ((enabled #t) + (size 3) + (passes 1) + (vibrancy 0.1696))))))) + +(define-public %default-hyprland-animations + (block (entries '((enabled #t) + (bezier "easeOutQuint,0.23,1,0.32,1") + (bezier "easeInOutCubic,0.65,0.05,0.36,1") + (bezier "linear,0,0,1,1") + (bezier "almostLinear,0.5,0.5,0.75,1.0") + (bezier "quick,0.15,0,0.1,1") + + (animation "global, 1, 10, default") + (animation "border, 1, 5.39, easeOutQuint") + (animation "windows, 1, 4.79, easeOutQuint") + (animation "windowsIn, 1, 4.1, easeOutQuint, popin 87%") + (animation "windowsOut, 1, 1.49, linear, popin 87%") + (animation "fadeIn, 1, 1.73, almostLinear") + (animation "fadeOut, 1, 1.46, almostLinear") + (animation "fade, 1, 3.03, quick") + (animation "layers, 1, 3.81, easeOutQuint") + (animation "layersIn, 1, 4, easeOutQuint, fade") + (animation "layersOut, 1, 1.5, linear, fade") + (animation "fadeLayersIn, 1, 1.79, almostLinear") + (animation "fadeLayersOut, 1, 1.39, almostLinear") + (animation "workspaces, 1, 1.94, almostLinear, fade") + (animation "workspacesIn, 1, 1.21, almostLinear, fade") + (animation "workspacesOut, 1, 1.94, almostLinear, fade"))))) + +(define-public %default-hyprland-workspace + '("w[tv1], gapsout:0, gapsin:0" "f[1], gapsout:0, gapsin:0")) + +(define-public %default-hyprland-windowrule + '("bordersize 0, floating:0, onworkspace:w[tv1]" + "rounding 0, floating:0, onworkspace:w[tv1]" + "bordersize 0, floating:0, onworkspace:f[1]" + "rounding 0, floating:0, onworkspace:f[1]")) + +(define-public %default-hyprland-misc + (block (entries '((force_default_wallpaper -1) + (disable_hyprland_logo #f) + (enable_swallow #t) + (vrr 2))))) + +(define-public %default-hyprland-gestures + (block (entries '((workspace_swipe #t))))) + +(define-public %default-hyprland-bindings + (bindings (main-mod "SUPER") + (binds `(,(binding (key "Q") + (action "killactive")) ,(binding (shift? #t) + (key "F") + (action + "togglefloating")) + ,(binding (key "F") + (action "fullscreen")) + ,(binding (shift? #t) + (key "R") + (action "exec") + (args "hyprctl reload")) + ;; Dwindle layout + ,(binding (key "P") + (action "pseudo")) + ,(binding (key "J") + (action "togglesplit")) + ;; Move focus with arrow keys + ,(binding (key "left") + (action "movefocus") + (args "l")) + ,(binding (key "right") + (action "movefocus") + (args "r")) + ,(binding (key "up") + (action "movefocus") + (args "u")) + ,(binding (key "down") + (action "movefocus") + (args "d")) + ;; Switch workspaces + ,@(map (lambda (index) + (binding (key (number->string index)) + (action "workspace") + (args (number->string index)))) + (iota 10)) + ;; Move active window to workspace + ,@(map (lambda (index) + (binding (shift? #t) + (key (number->string index)) + (action "movetoworkspace") + (args (number->string index)))) + (iota 10)) + ;; Move/resize with mouse + ,(binding (flags "m") + (key "mouse:272") + (action "movewindow")) + ,(binding (flags "m") + (key "mouse:273") + (action "resizewindow")) + ,(binding (key "R") + (action "submap") + (args "resize")))))) + +(define-public %hyprland-resize-submap + "submap = resize +binde = ,right, resizeactive, 10 0 +binde = ,left, resizeactive, -10 0 +binde = ,up, resizeactive, 0 -10 +binde = ,down, resizeactive, 0 10 +bind = ,escape, submap, reset +submap = reset +") + +(define-public %default-hyprland-configuration + (hyprland-configuration (general %default-hyprland-general) + (decoration %default-hyprland-decoration) + (animations %default-hyprland-animations) + (workspace %default-hyprland-workspace) + (windowrule %default-hyprland-windowrule) + (misc %default-hyprland-misc) + (gestures %default-hyprland-gestures) + (bindings %default-hyprland-bindings) + (extra-config %hyprland-resize-submap))) + +;;; +;;; Useful scripts +;;; + +;; Reload the first instance of hyprland, to +;; automatically load the new configuration +(define (hyprland-reload config) + #~(begin + (display "Reloading hyprland configuration...") + (system* #$(file-append (hyprland-configuration-package config) + "/bin/hyprctl") "--instance" "0" "reload"))) + +;;; +;;; Definition of the Home Service. +;;; + +(define-public home-hyprland-service-type + (service-type (name 'home-hyprland-config) + (description "Configure Sway by providing a file +@file{~/.config/hypr/hyprland.conf}.") + (compose (λ (extensions) + (hyprland-extension (exec-once (flatten (map + hyprland-extension-exec-once + extensions))) + (exec (flatten (map + hyprland-extension-exec + extensions))) + (bindings (flatten (map + hyprland-extension-bindings + extensions)))))) + (extend (λ (config rules) + (hyprland-configuration (inherit config) + (exec-once (append (hyprland-configuration-exec-once + config) + (hyprland-extension-exec-once + rules))) + (exec (append (hyprland-configuration-exec + config) + (hyprland-extension-exec + rules))) + (bindings (bindings (inherit + (hyprland-configuration-bindings + config)) + (binds (append + (bindings-binds + (hyprland-configuration-bindings + config)) + + (hyprland-extension-bindings + rules)))))))) + (extensions (list (service-extension + home-activation-service-type + ;; Trigger hyprctl reload after a new config has been applied + hyprland-reload) + (service-extension home-profile-service-type + (λ (config) + `(,(hyprland-configuration-package + config)))) + (service-extension + home-xdg-configuration-files-service-type + (λ (c) + `(("hypr/hyprland.conf" ,(mixed-text-file + "hyprland-cfg" + (serialize-configuration + c + hyprland-configuration-fields)))))))) + (default-value %default-hyprland-configuration))) base-commit: b282b5ecd90da5dc3a034e7064ac41808f7f6c24 -- 2.49.0 From unknown Fri Sep 19 14:23:35 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#77352] [PATCH] home: services: define hyprland home service Resent-From: Andrew Wong Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 29 Mar 2025 15:38:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 77352 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Carmine Margiotta , 77352@debbugs.gnu.org Received: via spool by 77352-submit@debbugs.gnu.org id=B77352.174326266722372 (code B ref 77352); Sat, 29 Mar 2025 15:38:02 +0000 Received: (at 77352) by debbugs.gnu.org; 29 Mar 2025 15:37:47 +0000 Received: from localhost ([127.0.0.1]:60893 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tyYFm-0005om-Sz for submit@debbugs.gnu.org; Sat, 29 Mar 2025 11:37:47 -0400 Received: from qs51p00im-qukt01071901.me.com ([17.57.155.8]:2863) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tyYFk-0005oW-No for 77352@debbugs.gnu.org; Sat, 29 Mar 2025 11:37:45 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=icloud.com; s=1a1hai; bh=ew60oUYIpBaWGG5eA/lCc/n32AHG28LtnxU0joU0fxQ=; h=Message-ID:Date:MIME-Version:Subject:To:From:Content-Type:x-icloud-hme; b=dER2FT9qqy2JhwZeEYyw9LtItFudNn1ZDFtHYHbOjxMtyvtiBLqt9AG6yMLsfguta aT+C7jK8L2RLvzLAt61Ow1T9UIjse+GX2fiCAGGYIqVPBZEBeJI5COVuYceU4OJ15e 4uraZBHmFX8kkGpnThaFC71xuuRGDj6uNEjAnapDvX0Q5mPZ0z+E27Ab8w158yLJ8A 6HW4se2ElyDjxHu5qfuZby5fCLjXQ3NRpm+/PuhAw00YFvlXrn4+TvhGGBgJqyHZRD qsd5xIl5w54xnLESD5OrfNRPRvjp7vSFcT+c8WHBhUeB0lTRn0Kcr8BVPE57QYVdFZ KBvCXcobRzrUg== Received: from [192.168.86.109] (qs51p00im-dlb-asmtp-mailmevip.me.com [17.57.155.28]) by qs51p00im-qukt01071901.me.com (Postfix) with ESMTPSA id E5F4C6280265; Sat, 29 Mar 2025 15:37:37 +0000 (UTC) Message-ID: <3b19a930-abf9-4f6a-baad-bb2c29e723e0@icloud.com> Date: Sat, 29 Mar 2025 11:37:36 -0400 MIME-Version: 1.0 User-Agent: Icedove Daily References: <20250328232510.32282-1-email@cmargiotta.net> <20250328232510.32282-2-email@cmargiotta.net> Content-Language: en-US From: Andrew Wong In-Reply-To: <20250328232510.32282-2-email@cmargiotta.net> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Proofpoint-GUID: e9vcuRy9RKD38NfPwakt_Z1dibl4DOD7 X-Proofpoint-ORIG-GUID: e9vcuRy9RKD38NfPwakt_Z1dibl4DOD7 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.1095,Hydra:6.0.680,FMLib:17.12.68.34 definitions=2025-03-29_01,2025-03-27_02,2024-11-22_01 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 bulkscore=0 malwarescore=0 spamscore=0 mlxscore=0 clxscore=1011 suspectscore=0 mlxlogscore=999 phishscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2308100000 definitions=main-2503290113 X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Very cool patch! Would it be possible to add functionality for loading plugins on startup? I have a pending patch series[1] that packages several Hyprland plugins, and it would be nice to be able to enter a list of plugin packages to be loaded directly in the config so they could be "dependencies" of the service. Also, how does this cooperate with session managers like the default GDM, which launches wayland from its .desktop entry in /run/current-system/profile/share/wayland-sessions[2]? If it only generates a configuration (i.e. doesn't start the Hyprland process), would it be possible to define services that start and run only while Hyprland runs? (this would be distinct from what "exec" lines do in that the packages are then pulled into the profile by the service, letting Guix "understand" the dependency) The default settings should be the same as Hyprland's auto-generated config[3], unless there's some guix-specific requirement. This is because users will want to be able to easily transfer the config they already use, and to be able to use the documentation and advice that already exists that assumes new users have the autogenerated config. Users should not have to do extra configuration to get a consistent default experience. To name a few issues, having `extra-config` defined by default would require users to go out of their way to use what would otherwise be a "last-resort" feature in order to get the default experience. Also, I know from experience that settings vrr to anything but 0 can cause some monitors to go black unless the vrr matches their (fixed) refresh rate; vrr is not a universal feature, the ability for the computer to control the monitor's vrr setting even less so. Perhaps the service could straight-up copy or parse-in the file (which would make transitioning from a "traditional" config file easy, too!) from the Hyprland package itself to reduce the need for Guix to maintain it every time it changes. Off the top of my head, the cheapest solution to the problem would be to hardcode the default config's checksum, and print an alert asking for maintenance when it changes. Finally, you should check over your patch with regards to Guix' coding style conventions[4]. Most conspicuously, lines should be 80 characters wide at maximum. Also, when updating a patch, you should send a v2 instead of creating a new bug number. Your patch shows a lot of promise, and it's great to see someone get the ball rolling on something I've only been daydreaming about for a while now. If you'd like help on any specific part, LMK! - Andrew Wong [1] bug#76910 [2] https://guix.gnu.org/manual/devel/en/html_node/X-Window.html#index-gdm_002dservice_002dtype [3] less $(guix build hyprland)/share/hypr/hyprland.conf [4] https://guix.gnu.org/manual/en/html_node/Formatting-Code.html From unknown Fri Sep 19 14:23:35 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#77352] [PATCH] home: services: define hyprland home service Resent-From: Carmine Margiotta Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 29 Mar 2025 17:40:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 77352 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 77352@debbugs.gnu.org Received: via spool by 77352-submit@debbugs.gnu.org id=B77352.174326996915103 (code B ref 77352); Sat, 29 Mar 2025 17:40:01 +0000 Received: (at 77352) by debbugs.gnu.org; 29 Mar 2025 17:39:29 +0000 Received: from localhost ([127.0.0.1]:32932 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tya9Z-0003vX-22 for submit@debbugs.gnu.org; Sat, 29 Mar 2025 13:39:29 -0400 Received: from out-12.smtp.spacemail.com ([198.54.127.83]:57055) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1tya9V-0003v7-T2 for 77352@debbugs.gnu.org; Sat, 29 Mar 2025 13:39:27 -0400 Received: from prod-lbout-phx.jellyfish.systems (unknown [198.177.122.3]) by smtp.spacemail.com (Postfix) with ESMTPA id 4ZQ4QG4lQSzC87Ms for <77352@debbugs.gnu.org>; Sat, 29 Mar 2025 17:39:18 +0000 (UTC) Received: from [192.168.8.194] (unknown [81.56.0.160]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mail.spacemail.com (Postfix) with ESMTPSA id 4ZQ4QG0VGMz8sWP for <77352@debbugs.gnu.org>; Sat, 29 Mar 2025 17:39:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cmargiotta.net; s=spacemail; t=1743269958; bh=B+ENdby3mzvZHG9hOsNwjKwVKrlpuOTJjOMPp7/tV0E=; h=Date:Subject:To:References:From:In-Reply-To:From; b=bk9DLNWhuU4IX2WI04ie5+tyCoxqek9+3oZ1JfVy9GB10zwxxBmBvfowHqIj864o0 zWoZF0WX7vzpp6RjDIKn92ixFTBOBLQO5izfaLeoZL8IZYJo562sbnOaSjom/f9xYQ cGT5GQsqjo+itw3M0uQ8e4QBBVUIoWbczMwAWNxoSOHr+OcehGcN7zD3LURSHBu7mA m3BXGov2u35XF3AkfT+Gwn2u685avJzQQWHqRkh7eMno1O2KA3AR+te8sbjfDgugM1 GQ/Nu9kE/fT8KSKGmeRG2KAI6bjlVCPekbaAGrI7BPJOhJ5+9Pdxq8AYri4cPd0Pqz QfVae2hy/UOLw== Message-ID: <233b800d-e1b5-4408-ab33-b52192857e86@cmargiotta.net> Date: Sat, 29 Mar 2025 18:39:15 +0100 MIME-Version: 1.0 User-Agent: Icedove Daily References: <20250328232510.32282-1-email@cmargiotta.net> <20250328232510.32282-2-email@cmargiotta.net> <3b19a930-abf9-4f6a-baad-bb2c29e723e0@icloud.com> Content-Language: en-US From: Carmine Margiotta In-Reply-To: <3b19a930-abf9-4f6a-baad-bb2c29e723e0@icloud.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) First of all, I apologize in advance for my mistakes, but this workflow is completely new to me! On 3/29/25 4:37 PM, Andrew Wong wrote: > Very cool patch! Would it be possible to add functionality for loading > plugins on startup? I have a pending patch series[1] that packages > several Hyprland plugins, and it would be nice to be able to enter a > list of plugin packages to be loaded directly in the config so they > could be "dependencies" of the service. This is a really interesting idea! I am not very familiar with Hyprland plugins - is there currently a declarative way to manage them? The only method I know is using hyprctl. > Also, how does this cooperate with session managers like the default > GDM, which launches wayland from its .desktop entry in > /run/current-system/profile/share/wayland-sessions[2]? If it only > generates a configuration (i.e. doesn't start the Hyprland process), > would it be possible to define services that start and run only while > Hyprland runs? (this would be distinct from what "exec" lines do in that > the packages are then pulled into the profile by the service, letting > Guix "understand" the dependency) This does not interact with session managers at all, it only generates a configuration without starting the process itself. For services that should run only while Hyprland is active, would this require managing Hyprland itself via shepherd? (I am still new to Guix, I might be mistaken here!) > The default settings should be the same as Hyprland's auto-generated > config[3], unless there's some guix-specific requirement. This is > because users will want to be able to easily transfer the config they > already use, and to be able to use the documentation and advice that > already exists that assumes new users have the autogenerated config. > Users should not have to do extra configuration to get a consistent > default experience. That makes perfect sense, I will fix that asap. > To name a few issues, having `extra-config` defined by default would > require users to go out of their way to use what would otherwise be a > "last-resort" feature in order to get the default experience. You raise a valid point, I will try to redesign this to implement submaps in a more coherent way. > Perhaps the service could straight-up copy or parse-in the file (which > would make transitioning from a "traditional" config file easy, too!) > from the Hyprland package itself to reduce the need for Guix to maintain > it every time it changes. Off the top of my head, the cheapest solution > to the problem would be to hardcode the default config's checksum, and > print an alert asking for maintenance when it changes. Your cheapest solution is good! > Finally, you should check over your patch with regards to Guix' coding > style conventions[4]. Most conspicuously, lines should be 80 characters > wide at maximum. Thank you for pointing this out. I did run guix style hyprland.scm --whole-file before submitting, but I see now that it doesn't catch line length violations. Could you recommend any additional linting tools that could help verify style compliance more thoroughly? I will be more careful next time, thank you! > Your patch shows a lot of promise, and it's great to see someone get the > ball rolling on something I've only been daydreaming about for a while > now. If you'd like help on any specific part, LMK! Thank you so much for your kind words! - Carmine Margiotta From unknown Fri Sep 19 14:23:35 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#77352] [PATCH] home: services: define hyprland home service Resent-From: Andrew Wong Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sun, 30 Mar 2025 02:07:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 77352 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Carmine Margiotta , 77352@debbugs.gnu.org Received: via spool by 77352-submit@debbugs.gnu.org id=B77352.17433003976255 (code B ref 77352); Sun, 30 Mar 2025 02:07:02 +0000 Received: (at 77352) by debbugs.gnu.org; 30 Mar 2025 02:06:37 +0000 Received: from localhost ([127.0.0.1]:33710 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tyi4L-0001co-1R for submit@debbugs.gnu.org; Sat, 29 Mar 2025 22:06:37 -0400 Received: from qs51p00im-qukt01071902.me.com ([17.57.155.9]:32347) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tyi4I-0001cX-8g for 77352@debbugs.gnu.org; Sat, 29 Mar 2025 22:06:35 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=icloud.com; s=1a1hai; bh=jffum/KCSULd8jNFULxF+62xuGbIRubLUDorke06BYM=; h=Message-ID:Date:MIME-Version:Subject:To:From:Content-Type:x-icloud-hme; b=yAUdEq5l2U7RpL4HQkuScNaO/+5VBKeYSHifhg7VOD/HZBmvCDqQernxBskzoLTrk I2LCqpoxGr78gIwo2EmY4+b+ay7T9BSmYAtITz0xMHuQQa+OVTz64ZuxwUbZDAe+5G /uCzQsHQXvqq6Nnmw19lrM5Vuo8uS9kSrwwQONVqAmTj9Xs2rjGor80X58tF2BzmBW KR3SW3SVYF1lFRxXyIPDUaTrAifMciIPc2Qxj2bXktHO5tcIXVqrN7rDMW7pBN6a1e hZfT37MX7BpL5+ezLlGW6/w6zEGGYHZkfW/LOObPbFWqfKtXBq0yzIk8gF3MnwxT/u Mws+tuQOFlOJA== Received: from [192.168.86.109] (qs51p00im-dlb-asmtp-mailmevip.me.com [17.57.155.28]) by qs51p00im-qukt01071902.me.com (Postfix) with ESMTPSA id 296D35EC029C; Sun, 30 Mar 2025 02:06:27 +0000 (UTC) Message-ID: <0877430f-20ec-4c08-9ff6-ab08476138b1@icloud.com> Date: Sat, 29 Mar 2025 22:06:26 -0400 MIME-Version: 1.0 User-Agent: Icedove Daily References: <20250328232510.32282-1-email@cmargiotta.net> <20250328232510.32282-2-email@cmargiotta.net> <3b19a930-abf9-4f6a-baad-bb2c29e723e0@icloud.com> <233b800d-e1b5-4408-ab33-b52192857e86@cmargiotta.net> Content-Language: en-US From: Andrew Wong In-Reply-To: <233b800d-e1b5-4408-ab33-b52192857e86@cmargiotta.net> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Proofpoint-GUID: 1ITjh1BqskzlIgTgoVSnJxx-6CJDoURO X-Proofpoint-ORIG-GUID: 1ITjh1BqskzlIgTgoVSnJxx-6CJDoURO X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1095,Hydra:6.0.680,FMLib:17.12.68.34 definitions=2025-03-30_01,2025-03-27_02,2024-11-22_01 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 clxscore=1015 suspectscore=0 malwarescore=0 mlxlogscore=999 bulkscore=0 adultscore=0 spamscore=0 phishscore=0 mlxscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2503300014 X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 3/29/25 1:39p, Carmine Margiotta wrote: > First of all, I apologize in advance for my mistakes, but this > workflow is completely new to me! No worries! Everyone starts somewhere. > This is a really interesting idea! I am not very familiar with > Hyprland plugins - is there currently a declarative way to manage > them? The only method I know is using hyprctl. I've been managing them declaratively by making `exec-once` calls to `hyprctl plugin load`, so maybe the service could use those. Another possiblity is fabricating hyprpm's state.[1] > This does not interact with session managers at all, it only > generates a configuration without starting the process itself. For > services that should run only while Hyprland is active, would this > require managing Hyprland itself via shepherd? (I am still new to > Guix, I might be mistaken here!) That's what I was wondering myself. Maybe it's possible to modify or wrap hyprland's .desktop entry to encapsulate the whole thing in a service? Like a hyprland.desktop that actually starts a service that runs the REAL hyprland.desktop session. That way you could construct your DE out of services configured in guix itself. > Could you recommend any additional linting tools that could help > verify style compliance more thoroughly? I will be more careful next > time, thank you! Are you editing using emacs? If so, you can use display-fill-column-mode to see the column limit. Otherwise, just skim through the style guide linked by the manual. A motion I do often after some heavy editing is typing C-M-u a few times to move a few scopes up, C-M-space to select the while s-expression, and then C-M-q to re-indent the region. [1] https://wiki.hyprland.org/Plugins/Using-Plugins/#hyprpm From unknown Fri Sep 19 14:23:35 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#77352] [PATCH v2] home: services: define hyprland home service References: <20250328232510.32282-2-email@cmargiotta.net> In-Reply-To: <20250328232510.32282-2-email@cmargiotta.net> Resent-From: Carmine Margiotta Original-Sender: "Debbugs-submit" Resent-CC: andrew@trop.in, janneke@gnu.org, ludo@gnu.org, tanguy@bioneland.org, guix-patches@gnu.org Resent-Date: Sun, 30 Mar 2025 17:13:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 77352 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 77352@debbugs.gnu.org Cc: Carmine Margiotta , andrew@trop.in, janneke@gnu.org, ludo@gnu.org, tanguy@bioneland.org X-Debbugs-Original-Xcc: andrew@trop.in, janneke@gnu.org, ludo@gnu.org, tanguy@bioneland.org Received: via spool by 77352-submit@debbugs.gnu.org id=B77352.174335474823017 (code B ref 77352); Sun, 30 Mar 2025 17:13:01 +0000 Received: (at 77352) by debbugs.gnu.org; 30 Mar 2025 17:12:28 +0000 Received: from localhost ([127.0.0.1]:37984 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tywCx-0005zA-6q for submit@debbugs.gnu.org; Sun, 30 Mar 2025 13:12:28 -0400 Received: from out-12.smtp.spacemail.com ([198.54.127.83]:54094) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1tywCt-0005yl-GK for 77352@debbugs.gnu.org; Sun, 30 Mar 2025 13:12:25 -0400 Received: from prod-lbout-phx.jellyfish.systems (unknown [198.177.122.3]) by smtp.spacemail.com (Postfix) with ESMTPA id 4ZQgmZ3m8KzC87qn; Sun, 30 Mar 2025 17:12:14 +0000 (UTC) Received: from localhost.localdomain (unknown [81.56.0.160]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mail.spacemail.com (Postfix) with ESMTPSA id 4ZQgmY3ksHz8sWN; Sun, 30 Mar 2025 17:12:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cmargiotta.net; s=spacemail; t=1743354734; bh=mAfghi6ZlHNG5J/iO8Wy8IoMF9W1fRNeaNLVDuzjGqw=; h=From:To:Cc:Subject:Date:From; b=MVDxAQW5JNR2fCb7v2pvCkGk3z6ADuHIpca6PCjQULR/ICIGY+ceNNAPcyEriM4Wh TM4v8Zp2Pb/39dXVvVWi0afgkjsmXVsd7EH2InoKiqM7dHwFQC+DREvjx5gH3KR7QK JySz+hnOhIraiwvUkXhxXEll4QiATQE91x8/Hbq2dH+MzQT4zAs66r0/bDYMvFCd2S wsCwKZg+j7nGwBJ5dYXyhncCFfjcAAd0OFeRDJ0aZao+AaQTBoaZ/Gf0CBLA1/nqRS YELf5BKdgR/xJqnOznj/YC+vzwFj22vLFBBs/oVoPgRNkMXhlCA6Ro0Z9tyhEysg24 HmLz57hQG7vYw== From: Carmine Margiotta Date: Sun, 30 Mar 2025 19:11:35 +0200 Message-ID: <20250330171201.16566-1-email@cmargiotta.net> X-Mailer: git-send-email 2.49.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --- gnu/home/services/hyprland.scm | 676 +++++++++++++++++++++++++++++++++ 1 file changed, 676 insertions(+) create mode 100644 gnu/home/services/hyprland.scm diff --git a/gnu/home/services/hyprland.scm b/gnu/home/services/hyprland.scm new file mode 100644 index 0000000000..3f2495ec0d --- /dev/null +++ b/gnu/home/services/hyprland.scm @@ -0,0 +1,676 @@ +;;; GNU Guix --- Functional package management for GNU +;;; Copyright © 2025 Carmine Margiotta +;;; +;;; This file is part of GNU Guix. +;;; +;;; GNU Guix is free software; you can redistribute it and/or modify it +;;; under the terms of the GNU General Public License as published by +;;; the Free Software Foundation; either version 3 of the License, or (at +;;; your option) any later version. +;;; +;;; GNU Guix is distributed in the hope that it will be useful, but +;;; WITHOUT ANY WARRANTY; without even the implied warranty of +;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;;; GNU General Public License for more details. +;;; +;;; You should have received a copy of the GNU General Public License +;;; along with GNU Guix. If not, see . + +(define-module (home home services hyprland) + #:use-module (gnu packages wm) + #:use-module (guix gexp) + #:use-module (guix modules) + #:use-module (gnu services configuration) + #:use-module (gnu home services) + #:use-module (guix packages) + #:use-module (ice-9 match) + #:use-module (srfi srfi-1) + + #:export (hyprland-extension + hyprland-configuration + binding + bindings + block + monitor + submap + home-hyprland-service-type)) + +;;; Commentary: +;;; +;;; A Guix Home service to configure Hyprland, an highly customizabile dynamic +;;; tiling Wayland compositor +;;; +;;; Code: + +;;; +;;; Helper functions. +;;; + +;;; Repeat v n times +(define (repeat v n) + (if (eq? n 0) + '() + `(,v ,@(repeat v + (- n 1))))) + +;;; Generate an indenter string of n tabs +(define (indent tabs) + (if (<= tabs 0) "" + (apply string-append + (repeat "\t" tabs)))) + +(define (flatten lst) + (let loop + ((lst lst) + (acc '())) + (cond + ((null? lst) + acc) + ((pair? lst) + (loop (car lst) + (loop (cdr lst) acc))) + (else (cons lst acc))))) + +;;; +;;; Definition of configurations. +;;; + +;;; Entry inside a 'block' configuration +;;; allowed formats: (symbol string) (symbol number) (symbol boolean) +;;; (symbol block-entries) +;;; A block entry can contain a list of block entries, effectively allowing +;;; nested blocks +(define (block-entry? data) + (or (null? data) + (match data + (((? symbol?) + (or (? string?) + (? number?) + (? boolean?) + (? block-entries?))) + #t)))) + +;;; List of block entries +(define (block-entries? data) + (every block-entry? data)) + +;;; An executable (a target for the exec action) can be a string or a gexp +(define (executable? value) + (or (string? value) + (gexp? value))) + +;;; A list of valid executables +(define (executable-list? values) + (every executable? values)) + +;;; Block sub-configuration (a container of block entries) +(define-configuration block + (entries (block-entries '()) "Block entries" + (serializer (λ (name value) + (serialize-block-entries name value 1))))) + +;;; Monitor sub-configuration +(define-configuration monitor + (name (string "") + "Monitor's name" + (serializer (λ (_ n) + (string-append "monitor = " n ", ")))) + (resolution (string "preferred") "Monitor's resolution" + (serializer (λ (_ n) + (string-append n ", ")))) + (position (string "auto") + "Monitor's position" + (serializer (λ (_ n) + (string-append n ", ")))) + (scale (string "auto") + "Monitor's scale" + (serializer (λ (_ n) + n))) + (transform (string "") + "Monitor's transform" + (serializer (λ (_ n) + (if (string-null? n) "\n" + (string-append ", transform, " n "\n")))))) + +;;; List of monitors definition +(define (monitors? arg) + (every monitor? arg)) + +;;; Environment variable +(define-configuration env + (name (string) + "Environemnt variable's name" + (serializer (λ (_ n) (string-append "env = " n ", ")))) + (value (string) + "Environment variable's value" + (serializer (λ (_ v) (string-append v "\n"))))) + +;;; List of environment variables +(define (env-list? arg) + (every env? arg)) + +;;; List of strings +(define (string-list? arg) + (every string? arg)) + +;;; Binding sub-configuration +(define-configuration binding + (flags (string "") + "Bind flags https://wiki.hyprland.org/Configuring/Binds/" + (serializer (λ (_ n) + (string-append "bind" n " = ")))) + (mod (string "$mod") + "Mod key" + (serializer (λ (_ n) + n))) + (shift? (boolean #f) + "If mod is shifted" + (serializer (λ (_ n) + (string-append (if n " SHIFT" "") ", ")))) + (key (string) + "Binding main key" + (serializer (λ (_ n) + (string-append n ", ")))) + (action (string "exec") + "Binding action" + (serializer (λ (_ n) + n))) + (args (executable "") + "Binding action's args" + (serializer (λ (name value) + (if (string? value) + (if (string-null? value) "\n" + (string-append ", " value "\n")) + #~(string-append ", " + #$(serialize-executable name value) + "\n")))))) + +;;; List of bindings +(define (binding-list? value) + (every binding? value)) + +(define (serialize-binding-list _ n) + #~(string-append + #$@(map (λ (b) + (serialize-configuration + b + binding-fields)) n))) + +;;; Submap configuration +(define-configuration submap + (name (string) + "Submap name" + (serializer (λ (_ name) (string-append "submap = " name "\n")))) + (bindings (binding-list) + "Bindings available only while this submap is active") + (escape (binding (binding + (mod "") + (key "escape") + (action "submap") + (args "reset"))) + "Binding used to go back to the global submap" + (serializer (λ (_ e) #~(string-append + #$(serialize-configuration e binding-fields) + "submap = reset\n"))))) + +;;; List of submaps +(define (submap-list? v) + (every submap? v)) + +;;; Optional string +(define-maybe/no-serialization string) + +;;; Binding block sub-configuration +(define-configuration bindings + (main-mod (maybe-string "") "Main mod bound to $mod" + (serializer (λ (_ n) + (string-append "\n$mod = " n "\n\n")))) + (binds (binding-list '()) "Bindings")) + +;;; +;;; Serialization functions. +;;; + +(define (serialize-block name block) + #~(string-append #$(symbol->string name) " {\n" + #$(if (null? block) "" + (serialize-configuration block + block-fields)) + "\n}\n")) + +(define (serialize-submap-list name submaps) + #~(string-append + #$@(map (λ (v) (serialize-configuration v submap-fields)) submaps))) + +(define (serialize-env-list name env) + #~(string-append + #$@(map (λ (v) (serialize-configuration v env-fields)) env))) + +;;; A block entry will be serialized as an indented hyprlang +;;; statement, nested blocks are allowed +(define (serialize-block-entry value tabs) + (string-append + (or (match value + (() "") + (((? symbol? name) + value) + (string-append + (indent tabs) + (symbol->string name) + (match value + ((? string? v) + (string-append " = " v)) + ((? number? v) + (string-append " = " + (number->string v))) + ((? boolean? v) + (if v " = true" " = false")) + ((? block-entries? v) + (string-append + " {\n" + (serialize-block-entries + #f v + (+ tabs 1)) + (indent tabs) "}"))) + "\n")) + ((_) + #f)) "\n"))) + +;;; String lists will be serialized as name = value\n +(define (serialize-string-list name values) + (apply string-append + (map (lambda (w) + (string-append (symbol->string name) " = " w "\n")) values))) + +;;; Gexp executables will be serialized on a program-file +(define (serialize-executable name value) + (if (string? value) value + (program-file (symbol->string name) value + #:module-path %load-path))) + +;;; Lists serializers +(define (serialize-block-entries _ entries level) + (apply string-append + (map (lambda (e) + (serialize-block-entry e level)) entries))) + +(define (serialize-monitors _ monitors) + #~(string-append #$@(map (lambda (m) + (serialize-configuration m monitor-fields)) + monitors))) + +(define (serialize-executable-list name values) + #~(apply string-append + (map (lambda (w) + (string-append #$(symbol->string name) " = " w "\n")) + '#$(map (lambda (v) + (serialize-executable name v)) values)))) + +;;; Hyprland full configuration +(define-configuration hyprland-configuration + (package + (package + hyprland) "Hyprland package to use" + (serializer (λ (_ n) ""))) + (monitors (monitors (list (monitor))) "Monitors definition") + (exec-once (executable-list '()) "Command to exec once") + (exec (executable-list '()) "Command to automatically exec") + (general (block (block)) "General configuration variables") + (decoration (block (block)) "Decoration configuration variables") + (animations (block (block)) "Animation configuration variables") + (workspace (string-list '()) "Workspaces settings") + (windowrule (string-list '()) "Window rules (v2)") + (dwindle (block (block)) "Dwindle layout settings") + (master (block (block)) "Master layout settings") + (misc (block (block)) "Misc settings") + (input (block (block)) "Input settings") + (gestures (block (block)) "Gestures settings") + (environment (env-list '()) "Environment variables") + (bindings (bindings (bindings)) "Bindings configuration" + (serializer (λ (_ n) + (serialize-configuration n bindings-fields)))) + (submaps (submap-list '()) "Submap configuration") + (extra-config (string "") "Extra config" + (serializer (λ (_ n) + (string-append n "\n"))))) + +;;; Hyprland configuration extension for other services +;;; External services can add new exec entries or new bindings +(define-configuration hyprland-extension + (exec-once (executable-list '()) + "Commands to be executed with hyprland once") + (exec (executable-list '()) "Commands to be executed with hyprland") + (bindings (binding-list '()) "Extra binds") + (no-serialization)) + +;;; +;;; Default settings and useful constants. +;;; +(define-public %default-hyprland-env + (list + (env (name "XCURSOR_SIZE") + (value "24")) + (env (name "HYPRCURSON_SIZE") + (value "24")))) + +(define-public %default-hyprland-windowrule + '("suppressevent maximize, class:.*" + "nofocus,class:^$,title:^$,xwayland:1,floating:1,fullscreen:0,pinned:0")) + +(define-public %default-hyprland-general + (block (entries '((gaps_in 5) + (gaps_out 20) + (border_size 2) + (col.active_border "rgba(33ccffee) rgba(00ff99ee) 45deg") + (col.inactive_border "rgba(595959aa)") + (resize_on_border #f) + (allow_tearing #f) + (layout "dwindle"))))) + +(define-public %default-hyprland-decoration + (block (entries '((rounding 10) + (rounding_power 2) + (active_opacity 1.0) + (inactive_opacity 1.0) + + (shadow ((enabled #t) + (range 4) + (render_power 3) + (color "rgba(1a1a1aee)"))) + (blur ((enabled #t) + (size 3) + (passes 1) + (vibrancy 0.1696))))))) + +(define-public %default-hyprland-animations + (block (entries + '((enabled #t) + (bezier "easeOutQuint,0.23,1,0.32,1") + (bezier "easeInOutCubic,0.65,0.05,0.36,1") + (bezier "linear,0,0,1,1") + (bezier "almostLinear,0.5,0.5,0.75,1.0") + (bezier "quick,0.15,0,0.1,1") + (animation "global, 1, 10, default") + (animation "border, 1, 5.39, easeOutQuint") + (animation "windows, 1, 4.79, easeOutQuint") + (animation "windowsIn, 1, 4.1, easeOutQuint, popin 87%") + (animation "windowsOut, 1, 1.49, linear, popin 87%") + (animation "fadeIn, 1, 1.73, almostLinear") + (animation "fadeOut, 1, 1.46, almostLinear") + (animation "fade, 1, 3.03, quick") + (animation "layers, 1, 3.81, easeOutQuint") + (animation "layersIn, 1, 4, easeOutQuint, fade") + (animation "layersOut, 1, 1.5, linear, fade") + (animation "fadeLayersIn, 1, 1.79, almostLinear") + (animation "fadeLayersOut, 1, 1.39, almostLinear") + (animation "workspaces, 1, 1.94, almostLinear, fade") + (animation "workspacesIn, 1, 1.21, almostLinear, fade") + (animation "workspacesOut, 1, 1.94, almostLinear, fade"))))) + +(define-public %default-hyprland-misc + (block (entries '((force_default_wallpaper -1) + (disable_hyprland_logo #f))))) + +(define-public %default-hyprland-dwindle + (block (entries '((pseudotile #t) + (preserve_split #t))))) + +(define-public %default-hyprland-master + (block (entries '((new_status "master"))))) + +(define-public %default-hyprland-input + (block (entries '((kb_layout "us") + (follow_mouse 1) + (sensitivity 0) + (touchpad ((natural_scroll #f))))))) + +(define-public %default-hyprland-gestures + (block (entries '((workspace_swipe #f))))) + +(define-public %default-hyprland-bindings + (bindings (main-mod "SUPER") + (binds `(,(binding (key "Q") + (action "exec") + (args "kitty")) + ,(binding (key "C") + (action "killactive")) + ,(binding (key "M") + (action "exit")) + ,(binding (key "E") + (action "exec") + (args "dolphin")) + ,(binding (key "V") + (action "togglefloating")) + ,(binding (key "R") + (action "exec") + (args "wofi --show dmenu")) + ;; Dwindle layout + ,(binding (key "P") + (action "pseudo")) + ,(binding (key "J") + (action "togglesplit")) + ;; Move focus with arrow keys + ,(binding (key "left") + (action "movefocus") + (args "l")) + ,(binding (key "right") + (action "movefocus") + (args "r")) + ,(binding (key "up") + (action "movefocus") + (args "u")) + ,(binding (key "down") + (action "movefocus") + (args "d")) + ;; Switch workspaces + ,@(map (lambda (index) + (binding (key (number->string index)) + (action "workspace") + (args (number->string index)))) + (iota 10)) + ;; Move active window to workspace + ,@(map (lambda (index) + (binding (shift? #t) + (key (number->string index)) + (action "movetoworkspace") + (args (number->string index)))) + (iota 10)) + ;; Scratchpad + ,(binding (key "S") + (action "togglespecialworkspace") + (args "magic")) + ,(binding (key "S") + (shift? #t) + (action "movetoworkspace") + (args "special:magic")) + ;; Scroll workspaces with mod + scroll + ,(binding (key "mouse_down") + (action "workspace") + (args "e+1")) + ,(binding (key "mouse_up") + (action "workspace") + (args "e-1")) + ;; Move/resize with mouse + ,(binding (flags "m") + (key "mouse:272") + (action "movewindow")) + ,(binding (flags "m") + (key "mouse:273") + (action "resizewindow")) + ;; Multimedia keys + ,(binding + (key "XF86AudioRaiseVolume") + (action "exec") + (args + "wpctl set-volume -l 1 @DEFAULT_AUDIO_SINK@ 5%+")) + ,(binding + (key "XF86AudioLowerVolume") + (action "exec") + (args + "wpctl set-volume -l 1 @DEFAULT_AUDIO_SINK@ 5%-")) + ,(binding + (key "XF86AudioMute") + (action "exec") + (args "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle")) + ,(binding + (key "XF86AudioMicMute") + (action "exec") + (args "wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle")) + ,(binding + (key "XF86MonBrightnessUp") + (action "exec") + (args "brightnessctl s 10%+")) + ,(binding + (key "XF86MonBrightnessDown") + (action "exec") + (args "brightnessctl s 10%-")) + ,(binding + (key "XF86AudioNext") + (action "exec") + (args "playerctl next")) + ,(binding + (key "XF86AudioPause") + (action "exec") + (args "playerctl play-pause")) + ,(binding + (key "XF86AudioPlay") + (action "exec") + (args "playerctl play-pause")) + ,(binding + (key "XF86AudioPrev") + (action "exec") + (args "playerctl previous")) + ,(binding (key "R") + (action "submap") + (args "resize")))))) + +(define-public %default-hyprland-configuration + (hyprland-configuration (general %default-hyprland-general) + (decoration %default-hyprland-decoration) + (animations %default-hyprland-animations) + (environment %default-hyprland-env) + (master %default-hyprland-master) + (windowrule %default-hyprland-windowrule) + (misc %default-hyprland-misc) + (input %default-hyprland-input) + (dwindle %default-hyprland-dwindle) + (gestures %default-hyprland-gestures) + (bindings %default-hyprland-bindings))) + +;;; +;;; Useful scripts +;;; + +;;; Obtained with string-hash-ci on the default hyprland.conf +;;; Maintainers can find the hash upgrades on home service logs too +(define %default-configuration-hash 970253705680761254) + +;;; Reload the first instance of hyprland to automatically load the new +;;; configuration. If the package's default configuration changes, after +;;; applying a new configuration, a warning notification is automatically +;;; shown on Hyprland until maintainers don't align the guix defaults +(define (hyprland-reload config) + (with-imported-modules + (source-module-closure + '((ice-9 textual-ports))) + #~(begin + (use-modules (ice-9 textual-ports)) + (display "Reloading hyprland configuration...\n") + (system* #$(file-append (hyprland-configuration-package config) + "/bin/hyprctl") + "--instance" "0" "reload") + (let ((hash (call-with-input-file + #$(file-append (hyprland-configuration-package config) + "/share/hypr/hyprland.conf") + (lambda (config) + (string-hash-ci (get-string-all config)))))) + (if (not (= hash + #$%default-configuration-hash)) + (begin + (display (string-append + "New hyprland default configuration detected, " + "hash value: " + (number->string hash) + "\n")) + (system* #$(file-append + (hyprland-configuration-package config) + "/bin/hyprctl") + "--instance" + "0" + "notify" + "0" ; this is a warning + "20000" ; 10s duration + "0" ; default color + "Package default configuration has changed, \ +please review your configuration and notify \ +the Guix service maintainer"))))))) + +;;; +;;; Definition of the Home Service. +;;; + +(define-public home-hyprland-service-type + (service-type (name 'home-hyprland-config) + (description "Configure Hyprland by providing a file +@file{~/.config/hypr/hyprland.conf}.") + (compose (λ (extensions) + (hyprland-extension (exec-once + (flatten + (map + hyprland-extension-exec-once + extensions))) + (exec (flatten + (map + hyprland-extension-exec + extensions))) + (bindings + (flatten + (map + hyprland-extension-bindings + extensions)))))) + (extend + (λ (config rules) + (hyprland-configuration + (inherit config) + (exec-once + (append + (hyprland-configuration-exec-once + config) + (hyprland-extension-exec-once + rules))) + (exec + (append (hyprland-configuration-exec + config) + (hyprland-extension-exec + rules))) + (bindings (bindings + (inherit + (hyprland-configuration-bindings + config)) + (binds (append + (bindings-binds + (hyprland-configuration-bindings + config)) + (hyprland-extension-bindings + rules)))))))) + (extensions + (list (service-extension + home-activation-service-type + ; Trigger hyprctl reload after + ; a new config has been applied + hyprland-reload) + (service-extension + home-profile-service-type + (λ (config) + `(,(hyprland-configuration-package + config)))) + (service-extension + home-xdg-configuration-files-service-type + (λ (c) + `(("hypr/hyprland.conf" + ,(mixed-text-file + "hyprland-cfg" + (serialize-configuration + c + hyprland-configuration-fields)))))))) + (default-value %default-hyprland-configuration))) base-commit: b282b5ecd90da5dc3a034e7064ac41808f7f6c24 -- 2.49.0 From unknown Fri Sep 19 14:23:35 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#77352] [PATCH v2] home: services: define hyprland home service Resent-From: Andrew Wong Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 31 Mar 2025 01:15:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 77352 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Carmine Margiotta , 77352@debbugs.gnu.org Cc: ludo@gnu.org, janneke@gnu.org, tanguy@bioneland.org, andrew@trop.in Received: via spool by 77352-submit@debbugs.gnu.org id=B77352.17433836882169 (code B ref 77352); Mon, 31 Mar 2025 01:15:02 +0000 Received: (at 77352) by debbugs.gnu.org; 31 Mar 2025 01:14:48 +0000 Received: from localhost ([127.0.0.1]:38578 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tz3jj-0000Yt-Hc for submit@debbugs.gnu.org; Sun, 30 Mar 2025 21:14:48 -0400 Received: from qs51p00im-qukt01071501.me.com ([17.57.155.4]:48895) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tz3jg-0000Xm-NQ for 77352@debbugs.gnu.org; Sun, 30 Mar 2025 21:14:45 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=icloud.com; s=1a1hai; bh=dJ4j8OgWssK+H+SCvof9R+urgIeiMFP2tD6rXThC+Mo=; h=Content-Type:Message-ID:Date:MIME-Version:Subject:To:From:x-icloud-hme; b=E5cvlO5Ce4B/KlUiC4pALh8Tm9CjMbrMFJODfn3+RnaD+evkS6dnzK61gWsQ1Z21f zBE+G1z1iNVb/K5m2bZplkt74N1DhYW+VUPkELUHzqpS8F33LeS6TS2uxHDz1bvnBv 5k1+IDwjaShvlHOeNdfSm8AJQygSpPf4Op6sYaHrXLwSASrBHsuxdw8NFKg7cL0y3D yBkx0CU5P58qiab3T7YkzlnLnfqtnz7Vmgm2gEgiAMAL4Hmm6P83V+vhOxSRpUm3/O Znr0xLV/ff7yQ0V/HCZExhZxhUNeM0ewaqKpgJsWVtJ7WxF7k2NUZyioS3yZX2Gcv0 8ySyW7pPGprWQ== Received: from [192.168.86.109] (qs51p00im-dlb-asmtp-mailmevip.me.com [17.57.155.28]) by qs51p00im-qukt01071501.me.com (Postfix) with ESMTPSA id 341D21C401B3; Mon, 31 Mar 2025 01:14:37 +0000 (UTC) Content-Type: multipart/mixed; boundary="------------4tCLueAZfoIlDGib4k0HhBhT" Message-ID: <88ab5741-089a-4cd3-bad5-e4cac1f039ef@icloud.com> Date: Sun, 30 Mar 2025 21:14:35 -0400 MIME-Version: 1.0 User-Agent: Icedove Daily References: <20250328232510.32282-2-email@cmargiotta.net> <20250330171201.16566-1-email@cmargiotta.net> Content-Language: en-US From: Andrew Wong In-Reply-To: <20250330171201.16566-1-email@cmargiotta.net> X-Proofpoint-GUID: 2kkveeDPJT0w7KY_vn5nRP5MEkcyzXa4 X-Proofpoint-ORIG-GUID: 2kkveeDPJT0w7KY_vn5nRP5MEkcyzXa4 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1095,Hydra:6.0.680,FMLib:17.12.68.34 definitions=2025-03-30_11,2025-03-27_02,2024-11-22_01 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxscore=0 suspectscore=0 bulkscore=0 malwarescore=0 spamscore=0 phishscore=0 mlxlogscore=999 clxscore=1011 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2503310007 X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) This is a multi-part message in MIME format. --------------4tCLueAZfoIlDGib4k0HhBhT Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Hello, I've suggested some small changes which I've attached as patches. I also have some questions and comments: On 3/30/25 1:11p, Carmine Margiotta wrote:> +;;; Gexp executables will be serialized on a program-file > +(define (serialize-executable name value) > + (if (string? value) value > + (program-file (symbol->string name) value > + #:module-path %load-path)) How will you serialize g-expressions? It seems that they are to be added to the store as scripts with 'program-file', but I can't figure out how to extract the file path from the resulting object; I tried in a REPL, program-file objects cannot be used as strings like this function seems to suggest, and none of the their properties seem to clearly give their location in the store. Also, how are you testing your work? I asked in the IRC channel and they suggested spooling up a VM via 'guix system vm' with an operating-system definition containing the experimental service, but perhaps you have your own method. --------------4tCLueAZfoIlDGib4k0HhBhT Content-Type: text/x-patch; charset=UTF-8; name="0001-home-services-hyprland-default-hyprland-env-Fix-typo.patch" Content-Disposition: attachment; filename*0="0001-home-services-hyprland-default-hy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gIjI0IikpCi0gICAoZW52IChuYW1lICJIWVBSQ1VSU09OX1NJWkUiKQorICAg KGVudiAobmFtZSAiSFlQUkNVUlNPUl9TSVpFIikKICAgICAgICAgKHZhbHVlICIyNCIpKSkp CiAKIChkZWZpbmUtcHVibGljICVkZWZhdWx0LWh5cHJsYW5kLXdpbmRvd3J1bGUKCmJhc2Ut Y29tbWl0OiAzNTNmNzcyNGIyNmQ3Mjk4NmVhYjRlMTgxZGMzNDI5MDQ3NTVhNWQ2Ci0tIAoy LjQ5LjAKCg== --------------4tCLueAZfoIlDGib4k0HhBhT Content-Type: text/x-patch; charset=UTF-8; name="0002-home-services-hyprland-default-hyprland-bindings-Rem.patch" Content-Disposition: attachment; filename*0="0002-home-services-hyprland-default-hyprland-bindings-Rem.pa"; filename*1="tch" Content-Transfer-Encoding: base64 RnJvbSA3NDZhMWQ1ZWM2N2Y5Njk2NWQ4MGIyODBmYzg3ODNiZGM3ZTY4YTAxIE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpNZXNzYWdlLUlEOiA8NzQ2YTFkNWVjNjdmOTY5NjVkODBiMjgw ZmM4NzgzYmRjN2U2OGEwMS4xNzQzMzgxODAxLmdpdC53b25nYW5kakBpY2xvdWQuY29tPgpJ bi1SZXBseS1UbzogPDBkMmM3MjQ0MWQ5YjRhOTRhZGVkNmQ1MzAyOGQ2M2IyNTNmNWU3YWUu MTc0MzM4MTgwMS5naXQud29uZ2FuZGpAaWNsb3VkLmNvbT4KUmVmZXJlbmNlczogPDBkMmM3 MjQ0MWQ5YjRhOTRhZGVkNmQ1MzAyOGQ2M2IyNTNmNWU3YWUuMTc0MzM4MTgwMS5naXQud29u Z2FuZGpAaWNsb3VkLmNvbT4KRnJvbTogQW5kcmV3IFdvbmcgPHdvbmdhbmRqQGljbG91ZC5j b20+CkRhdGU6IFN1biwgMzAgTWFyIDIwMjUgMTU6MTc6MjQgLTA0MDAKU3ViamVjdDogW1BB VENIIDIvNV0gaG9tZTogc2Vydmlj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ZXkgIlIiKQotICAgICAgICAgICAgICAgICAg ICAgICAgICAgICAgIChhY3Rpb24gInN1Ym1hcCIpCi0gICAgICAgICAgICAgICAgICAgICAg ICAgICAgICAgKGFyZ3MgInJlc2l6ZSIpKSkpKSkKKyAgICAgICAgICAgICAgICAgICAgICAg KGFyZ3MgInBsYXllcmN0bCBwcmV2aW91cyIpKSkpKSkKIAogKGRlZmluZS1wdWJsaWMgJWRl ZmF1bHQtaHlwcmxhbmQtY29uZmlndXJhdGlvbgogICAoaHlwcmxhbmQtY29uZmlndXJhdGlv biAoZ2VuZXJhbCAlZGVmYXVsdC1oeXBybGFuZC1nZW5lcmFsKQotLSAKMi40OS4wCgo= --------------4tCLueAZfoIlDGib4k0HhBhT Content-Type: text/x-patch; charset=UTF-8; name="0003-home-services-hyprland-hyprland-reload-Reword-phrase.patch" Content-Disposition: attachment; filename*0="0003-home-services-hyprland-hyprland-reload-Reword-phrase.pa"; filename*1="tch" Content-Transfer-Encoding: base64 RnJvbSBjOGIwYWMxNjRiZThlZWRmOTNhMjZlYWZlMGUxYjEyNDMwMDg2MTM5IE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpNZXNzYWdlLUlEOiA8YzhiMGFjMTY0YmU4ZWVkZjkzYTI2ZWFm ZTBlMWIxMjQzMDA4NjEzOS4xNzQzMzgxODAxLmdpdC53b25nYW5kakBpY2xvdWQuY29tPgpJ bi1SZXBseS1UbzogPDBkMmM3MjQ0MWQ5YjRhOTRhZGVkNmQ1MzAyOGQ2M2IyNTNmNWU3YWUu MTc0MzM4MTgwMS5naXQud29uZ2FuZGpAaWNsb3VkLmNvbT4KUmVmZXJlbmNlczogPDBkMmM3 MjQ0MWQ5YjRhOTRhZGVkNmQ1MzAyOGQ2M2IyNTNmNWU3YWUuMTc0MzM4MTgwMS5naXQud29u Z2FuZGpAaWNsb3VkLmNvbT4KRnJvbTogQW5kcmV3IFdvbmcgPHdvbmdhbmRqQGljbG91ZC5j b20+CkRhdGU6IFN1bi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3VpeEBnbnUub3JnLiIpKSkpKSkpCiAKIDs7OwogOzs7IERlZmluaXRpb24gb2YgdGhl IEhvbWUgU2VydmljZS4KLS0gCjIuNDkuMAoK --------------4tCLueAZfoIlDGib4k0HhBhT Content-Type: text/x-patch; charset=UTF-8; name="0004-home-services-hyprland-Localize-flatten.patch" Content-Disposition: attachment; filename="0004-home-services-hyprland-Localize-flatten.patch" Content-Transfer-Encoding: base64 RnJvbSA2NTlkNzkxMjg5YmUzODA3ZGFkYTQxMjg5MGVmZDQ2YTMwOWM1MWFhIE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpNZXNzYWdlLUlEOiA8NjU5ZDc5MTI4OWJlMzgwN2RhZGE0MTI4 OTBlZmQ0NmEzMDljNTFhYS4xNzQzMzgxODAxLmdpdC53b25nYW5kakBpY2xvdWQuY29tPgpJ bi1SZXBseS1UbzogPDBkMmM3MjQ0MWQ5YjRhOTRhZGVkNmQ1MzAyOGQ2M2IyNTNmNWU3YWUu MTc0MzM4MTgwMS5naXQud29uZ2FuZGpAaWNsb3VkLmNvbT4KUmVmZXJlbmNlczogPDBkMmM3 MjQ0MWQ5YjRhOTRhZGVkNmQ1MzAyOGQ2M2IyNTNmNWU3YWUuMTc0MzM4MTgwMS5naXQud29u Z2FuZGpAaWNsb3VkLmNvbT4KRnJvbTogQW5kcmV3IFdvbmcgPHdvbmdhbmRqQGljbG91ZC5j b20+CkRhdGU6IFN1biwgMzAgTWFyIDIwMjUgMTc6MDI6MjIgLTA0MDAKU3ViamVjdDogW1BB VENIIDQvNV0gaG9tZTogc2VydmljZXM6IGh5cHJsYW5kOiBMb2NhbGl6ZSAnZmxhdHRlbicK CmhvbWU6IHNlcnZpY2VzOiBoeXBybGFuZChob21lLWh5cHJsYW5kLXNlcnZpY2UtdHlwZSk6 IExvY2FsaXplICdmbGF0dGVuJy4KaG9tZTogc2VydmljZXM6IGh5cHJsYW5kKGZsYXR0ZW4p OiBEZWxldGUuCkNoYW5nZS1JZDogSW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G5hbWUgJ2hvbWUtaHlwcmxhbmQtY29uZmln KQogICAgICAgICAgICAgICAgIChkZXNjcmlwdGlvbiAiQ29uZmlndXJlIEh5cHJsYW5kIGJ5 IHByb3ZpZGluZyBhIGZpbGUKIEBmaWxle34vLmNvbmZpZy9oeXByL2h5cHJsYW5kLmNvbmZ9 LiIpCi0gICAgICAgICAgICAgICAgKGNvbXBvc2UgKM67IChleHRlbnNpb25zKQotICAgICAg ICAgICAgICAgICAgICAgICAgICAgKGh5cHJsYW5kLWV4dGVuc2lvbiAoZXhlYy1vbmNlCi0g ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAoZmxhdHRl bgotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICht YXAKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAg aHlwcmxhbmQtZXh0ZW5zaW9uLWV4ZWMtb25jZQotICAgICAgICAgICAgICAgICAgICAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgICBleHRlbnNpb25zKSkpCi0gICAgICAgICAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIChleGVjIChmbGF0dGVuCi0gICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAobWFw Ci0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAg ICAgaHlwcmxhbmQtZXh0ZW5zaW9uLWV4ZWMKLSAgICAgICAgICAgICAgICAgICAgICAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICBleHRlbnNpb25zKSkpCi0gICAgICAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIChiaW5kaW5ncwotICAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKGZsYXR0ZW4KLSAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAobWFwCi0g ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGh5cHJs YW5kLWV4dGVuc2lvbi1iaW5kaW5ncwotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAg ICAgICAgICAgICAgICAgICAgICBleHRlbnNpb25zKSkpKSkpCisgICAgICAgICAgICAgICAg KGNvbXBvc2UKKyAgICAgICAgICAgICAgICAgKM67IChleHRlbnNpb25zKQorICAgICAgICAg ICAgICAgICAgIChsZXQgKChmbGF0dGVuIGxzdCkKKyAgICAgICAgICAgICAgICAgICAgICAg ICAobGV0IGxvb3AgKChsc3QgbHN0KSAoYWNjICcoKSkpCisgICAgICAgICAgICAgICAgICAg ICAgICAgICAoY29uZCAoKG51bGw/IGxzdCkgYWNjKQorICAgICAgICAgICAgICAgICAgICAg ICAgICAgICAgICAgKChwYWlyPyBsc3QpIChsb29wIChjYXIgbHN0KQorICAgICAgICAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIChsb29wIChjZHIgbHN0 KSBhY2MpKSkKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIChlbHNlIChjb25z IGxzdCBhY2MpKSkpKQorICAgICAgICAgICAgICAgICAgICAgKGh5cHJsYW5kLWV4dGVuc2lv bgorICAgICAgICAgICAgICAgICAgICAgIChleGVjLW9uY2UKKyAgICAgICAgICAgICAgICAg ICAgICAgKGZsYXR0ZW4gKG1hcCBoeXBybGFuZC1leHRlbnNpb24tZXhlYy1vbmNlIGV4dGVu c2lvbnMpKSkKKyAgICAgICAgICAgICAgICAgICAgICAoZXhlYyAoZmxhdHRlbiAobWFwIGh5 cHJsYW5kLWV4dGVuc2lvbi1leGVjCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAg ICAgICAgICAgICBleHRlbnNpb25zKSkpCisgICAgICAgICAgICAgICAgICAgICAgKGJpbmRp bmdzIChmbGF0dGVuIChtYXAgaHlwcmxhbmQtZXh0ZW5zaW9uLWJpbmRpbmdzCisgICAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZXh0ZW5zaW9ucykpKSkp KSkKICAgICAgICAgICAgICAgICAoZXh0ZW5kCiAgICAgICAgICAgICAgICAgICjOuyAoY29u ZmlnIHJ1bGVzKQogICAgICAgICAgICAgICAgICAgIChoeXBybGFuZC1jb25maWd1cmF0aW9u Ci0tIAoyLjQ5LjAKCg== --------------4tCLueAZfoIlDGib4k0HhBhT Content-Type: text/x-patch; charset=UTF-8; name="0005-home-services-hyprland-Localize-indent.patch" Content-Disposition: attachment; filename="0005-home-services-hyprland-Localize-indent.patch" Content-Transfer-Encoding: base64 RnJvbSA3MGRkMDE0OWY3NzdlYWU5ZjRlYTRhNGM3ZDkyY2EwNThiMWU3NmJmIE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpNZXNzYWdlLUlEOiA8NzBkZDAxNDlmNzc3ZWFlOWY0ZWE0YTRj N2Q5MmNhMDU4YjFlNzZiZi4xNzQzMzgxODAxLmdpdC53b25nYW5kakBpY2xvdWQuY29tPgpJ bi1SZXBseS1UbzogPDBkMmM3MjQ0MWQ5YjRhOTRhZGVkNmQ1MzAyOGQ2M2IyNTNmNWU3YWUu MTc0MzM4MTgwMS5naXQud29uZ2FuZGpAaWNsb3VkLmNvbT4KUmVmZXJlbmNlczogPDBkMmM3 MjQ0MWQ5YjRhOTRhZGVkNmQ1MzAyOGQ2M2IyNTNmNWU3YWUuMTc0MzM4MTgwMS5naXQud29u Z2FuZGpAaWNsb3VkLmNvbT4KRnJvbTogQW5kcmV3IFdvbmcgPHdvbmdhbmRqQGljbG91ZC5j b20+CkRhdGU6IFN1biwgMzAgTWFyIDIwMjUgMTc6MjA6MzEgLTA0MDAKU3ViamVjdDogW1BB VENIIDUvNV0gaG9tZTogc2VydmljZXM6IGh5cHJsYW5kOiBMb2NhbGl6ZSAnaW5kZW50JwoK aG9tZTogc2VydmljZXM6I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IHRhYnMpCi0gIChpZiAoPD0gdGFicyAwKSAiIgotICAgICAg KGFwcGx5IHN0cmluZy1hcHBlbmQKLSAgICAgICAgICAgICAocmVwZWF0ICJcdCIgdGFicykp KSkKLQogOzs7CiA7OzsgRGVmaW5pdGlvbiBvZiBjb25maWd1cmF0aW9ucy4KIDs7OwpAQCAt MjQyLDI1ICsyMjUsMjIgQEAgKGRlZmluZSAoc2VyaWFsaXplLWJsb2NrLWVudHJ5IHZhbHVl IHRhYnMpCiAgICAgICAgICAoKCkgIiIpCiAgICAgICAgICAoKCg/IHN5bWJvbD8gbmFtZSkK ICAgICAgICAgICAgdmFsdWUpCi0gICAgICAgICAgKHN0cmluZy1hcHBlbmQKLSAgICAgICAg ICAgKGluZGVudCB0YWJzKQotICAgICAgICAgICAoc3ltYm9sLT5zdHJpbmcgbmFtZSkKLSAg ICAgICAgICAgKG1hdGNoIHZhbHVlCi0gICAgICAgICAgICAgKCg/IHN0cmluZz8gdikKLSAg ICAgICAgICAgICAgKHN0cmluZy1hcHBlbmQgIiA9ICIgdikpCi0gICAgICAgICAgICAgKCg/ IG51bWJlcj8gdikKLSAgICAgICAgICAgICAgKHN0cmluZy1hcHBlbmQgIiA9ICIKLSAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgKG51bWJlci0+c3RyaW5nIHYpKSkKLSAgICAgICAg ICAgICAoKD8gYm9vbGVhbj8gdikKLSAgICAgICAgICAgICAgKGlmIHYgIiA9IHRydWUiICIg PSBmYWxzZSIpKQotICAgICAgICAgICAgICgoPyBibG9jay1lbnRyaWVzPyB2KQotICAgICAg ICAgICAgICAoc3RyaW5nLWFwcGVuZAotICAgICAgICAgICAgICAgIiB7XG4iCi0gICAgICAg ICAgICAgICAoc2VyaWFsaXplLWJsb2NrLWVudHJpZXMKLSAgICAgICAgICAgICAgICAjZiB2 Ci0gICAgICAgICAgICAgICAgKCsgdGFicyAxKSkKLSAgICAgICAgICAgICAgIChpbmRlbnQg dGFicykgIn0iKSkpCi0gICAgICAgICAgICJcbiIpKQorICAgICAgICAgIChsZXQgKGluZGVu dCAobWFrZS1zdHJpbmcgKG1heCAwIHRhYnMpICNcdGFiKSkKKyAgICAgICAgICAgIChzdHJp bmctYXBwZW5kCisgICAgICAgICAgICAgKGluZGVudCB0YWJzKQorICAgICAgICAgICAgIChz eW1ib2wtPnN0cmluZyBuYW1lKQorICAgICAgICAgICAgIChtYXRjaCB2YWx1ZQorICAgICAg ICAgICAgICAgKCg/IHN0cmluZz8gdikKKyAgICAgICAgICAgICAgICAoc3RyaW5nLWFwcGVu ZCAiID0gIiB2KSkKKyAgICAgICAgICAgICAgICgoPyBudW1iZXI/IHYpCisgICAgICAgICAg ICAgICAgKHN0cmluZy1hcHBlbmQgIiA9ICIgKG51bWJlci0+c3RyaW5nIHYpKSkKKyAgICAg ICAgICAgICAgICgoPyBib29sZWFuPyB2KQorICAgICAgICAgICAgICAgIChpZiB2ICIgPSB0 cnVlIiAiID0gZmFsc2UiKSkKKyAgICAgICAgICAgICAgICgoPyBibG9jay1lbnRyaWVzPyB2 KQorICAgICAgICAgICAgICAgIChzdHJpbmctYXBwZW5kICIge1xuIgorICAgICAgICAgICAg ICAgICAgICAgICAgICAgICAgIChzZXJpYWxpemUtYmxvY2stZW50cmllcyAjZiB2ICgrIHRh YnMgMSkpCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKGluZGVudCB0YWJzKSAi fSIpKSkKKyAgICAgICAgICAgICAiXG4iKSkpCiAgICAgICAgICAoKF8pCiAgICAgICAgICAg I2YpKSAiXG4iKSkpCiAKLS0gCjIuNDkuMAoK --------------4tCLueAZfoIlDGib4k0HhBhT-- From unknown Fri Sep 19 14:23:35 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#77352] [PATCH v2] home: services: define hyprland home service Resent-From: Carmine Margiotta Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 31 Mar 2025 20:15:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 77352 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Andrew Wong , 77352@debbugs.gnu.org Cc: ludo@gnu.org, janneke@gnu.org, tanguy@bioneland.org, andrew@trop.in Received: via spool by 77352-submit@debbugs.gnu.org id=B77352.174345208028176 (code B ref 77352); Mon, 31 Mar 2025 20:15:02 +0000 Received: (at 77352) by debbugs.gnu.org; 31 Mar 2025 20:14:40 +0000 Received: from localhost ([127.0.0.1]:43043 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tzLWq-0007KM-1R for submit@debbugs.gnu.org; Mon, 31 Mar 2025 16:14:40 -0400 Received: from out-13.smtp.spacemail.com ([63.250.43.96]:32423) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1tzLWn-0007JS-W4 for 77352@debbugs.gnu.org; Mon, 31 Mar 2025 16:14:38 -0400 Received: from prod-lbout-phx.jellyfish.systems (unknown [198.177.122.3]) by smtp.spacemail.com (Postfix) with ESMTPA id 4ZRMmN40xCzC8986; Mon, 31 Mar 2025 20:14:28 +0000 (UTC) Received: from [192.168.8.194] (unknown [81.56.0.160]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mail.spacemail.com (Postfix) with ESMTPSA id 4ZRMmM1CRYz2x99; Mon, 31 Mar 2025 20:14:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cmargiotta.net; s=spacemail; t=1743452068; bh=N/dcFnNvlNuxjyQIaRHrGXgnjgzMOUj97vz3IS9Exdw=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=AoDD2w/6UuENn+2Q873m8dBmC6A7DKqwHuALidAGIuBLQTFcxPRvaVl8+mh3iO8Zt bNl5xI7V3xYKQpVZxAMxoRiJ+mHyeQwQwVl41TwboYJDFdghDtJBQXfSwVOLqlxQjc xFeFeJr1hzXsxpP9kOqIvbY6YrP7YZxkHH0UufyBvrwD2i53BI0QxirZKOgHtN2OMw Qi046Plt8pcvgWAJgrFqI38CTkYDD4rpHVD0tWNP8oTwUEhqC/l2N1Nb26q5QRmosH bKDoTjB+zWndI8ZgNfYf5Ixv8pepg63duE2vqa/oXoqqmZqQ8J/I0PNMj2kXcb546Q xxCiehDYFJlrg== Message-ID: <99e74082-83b2-413e-926c-0f22d8d8c819@cmargiotta.net> Date: Mon, 31 Mar 2025 22:14:25 +0200 MIME-Version: 1.0 User-Agent: Icedove Daily References: <20250328232510.32282-2-email@cmargiotta.net> <20250330171201.16566-1-email@cmargiotta.net> <88ab5741-089a-4cd3-bad5-e4cac1f039ef@icloud.com> Content-Language: en-US From: Carmine Margiotta In-Reply-To: <88ab5741-089a-4cd3-bad5-e4cac1f039ef@icloud.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hello Andrew, thank you for your patches! On 3/31/25 03:14, Andrew Wong wrote: > How will you serialize g-expressions? It seems that they are to be added > to the store as scripts with 'program-file', but I can't figure out how > to extract the file path from the resulting object; I tried in a REPL, > program-file objects cannot be used as strings like this function seems > to suggest, and none of the their properties seem to clearly give their > location in the store. As stated in the define-configuration documentation[1], serialization procedures should return strings or g-expressions; in case of program-file a g-expression that will ungexp to the script's path will be returned and the result will be something like: "exec = /gnu/store/h98yjz6b2rhmxr48c11cy84d3nwf6a7x-exec" > Also, how are you testing your work? I asked in the IRC channel and they > suggested spooling up a VM via 'guix system vm' with an operating-system > definition containing the experimental service, but perhaps you have > your own method. This matches my current workflow perfectly. I used to develop this service directly in my system configuration, but that wasn’t the best way to test this kind of code. Using a VM is actually pretty straightforward! If you need anything about that, feel free to ask me. [1] https://guix.gnu.org/manual/en/html_node/Complex-Configurations.html From unknown Fri Sep 19 14:23:35 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#77352] [PATCH] home: services: define hyprland home service References: <20250328232510.32282-2-email@cmargiotta.net> In-Reply-To: <20250328232510.32282-2-email@cmargiotta.net> Resent-From: Daniel Ziltener Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 05 Apr 2025 01:01:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 77352 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 77352@debbugs.gnu.org Received: via spool by 77352-submit@debbugs.gnu.org id=B77352.174381483121189 (code B ref 77352); Sat, 05 Apr 2025 01:01:02 +0000 Received: (at 77352) by debbugs.gnu.org; 5 Apr 2025 01:00:31 +0000 Received: from localhost ([127.0.0.1]:40697 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1u0rte-0005Vh-Mt for submit@debbugs.gnu.org; Fri, 04 Apr 2025 21:00:31 -0400 Received: from 195-15-241-199.dc3-a.pub1.etik-cloud.com ([195.15.241.199]:52815 helo=lyrion.ch) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1u0rtZ-0005VO-4a for 77352@debbugs.gnu.org; Fri, 04 Apr 2025 21:00:28 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lyrion.ch; s=20230702; t=1743814820; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type; bh=RusYmCk3VzphcsdouNQOqijxhwzi/j/oEPFuDAniyU4=; b=yukRmdPKJJhRlM0B9PqnCLIOsJtfJldHjUp7onCSNYfOT0+wI4Ac3ufZPaAwMI3nFMAa6z L4uTOZm4o9KLsP6I9nfX2Jpaj+qLPOXKQ7NzE9bsA7/P7JsZjtdqlYyI8fTMrs+TgQ42/4 SiXcxWXkSR1rwR6MTfPTLTWeJt6furgK+5LukPME2nflpsElJ0rmWai8b5pI5RBI0APtDZ jyWdMgnK/XL3TtnRJKktqXMyZZm5Nd2MiIUWln5Hj1aRIKWJUkUWNnlmBDeC1A2obhDFd1 Fd4buLznrOYCKzuJlqxAj8TUWvjavAzPU/VyrF9CHSyptzAJCQDtq3/xXVKcYw== Received: from [192.168.178.53] (cf597899.dynamic.tele-ag.de [207.89.120.153]) by lyrion.ch (OpenSMTPD) with ESMTPSA id db8783ed (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO) for <77352@debbugs.gnu.org>; Sat, 5 Apr 2025 01:00:20 +0000 (UTC) Content-Type: multipart/alternative; boundary="------------4ufR3nFwrT3liERmkJ753E0B" Message-ID: <9be151a9-3662-4623-bd25-35d278cf3ea4@lyrion.ch> Date: Sat, 5 Apr 2025 03:00:20 +0200 MIME-Version: 1.0 User-Agent: Icedove Daily Content-Language: en-US From: Daniel Ziltener X-Spam-Score: 0.4 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.6 (/) This is a multi-part message in MIME format. --------------4ufR3nFwrT3liERmkJ753E0B Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 3/29/25 10:06p, Andrew Wong wrote: > I've been managing them declaratively by making `exec-once` calls to > `hyprctl plugin load`, so maybe the service could use those. Another > possiblity is fabricating hyprpm's state. No need to do that - you can add lines like this to the hyprland.conf: ``` plugin=/gnu/store/bpcyf6hwzg15iidki24v51iak05skcqx-hyprland-plugin-hyprscroller-0.48.1/lib/hyprscroller.so ``` --------------4ufR3nFwrT3liERmkJ753E0B Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit
On 3/29/25 10:06p, Andrew Wong wrote:

> I've been managing them declaratively by making `exec-once` calls to
> `hyprctl plugin load`, so maybe the service could use those. Another 
> possiblity is fabricating hyprpm's state.

No need to do that - you can add lines like this to the hyprland.conf:

```
plugin=/gnu/store/bpcyf6hwzg15iidki24v51iak05skcqx-hyprland-plugin-hyprscroller-0.48.1/lib/hyprscroller.so
```


--------------4ufR3nFwrT3liERmkJ753E0B--