From patchwork Mon Oct 10 16:57:06 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\\(" X-Patchwork-Id: 43305 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 3C36727BBEA; Mon, 10 Oct 2022 18:10:38 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id ED25427BBE9 for ; Mon, 10 Oct 2022 18:10:37 +0100 (BST) Received: from localhost ([::1]:34800 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ohwIX-0007x0-2n for patchwork@mira.cbaines.net; Mon, 10 Oct 2022 13:10:37 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42340) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ohwD8-0004u2-Rl for guix-patches@gnu.org; Mon, 10 Oct 2022 13:05:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:50654) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ohwD8-0000jW-5R for guix-patches@gnu.org; Mon, 10 Oct 2022 13:05:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ohwD7-0002Js-Ki for guix-patches@gnu.org; Mon, 10 Oct 2022 13:05:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#56961] [PATCH v2 1/4] gnu: packages: Add go-github-com-delthas-tcell. References: In-Reply-To: Resent-From: "(" Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 10 Oct 2022 17:05:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 56961 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 56961@debbugs.gnu.org Cc: "\(" Received: via spool by 56961-submit@debbugs.gnu.org id=B56961.16654214548830 (code B ref 56961); Mon, 10 Oct 2022 17:05:01 +0000 Received: (at 56961) by debbugs.gnu.org; 10 Oct 2022 17:04:14 +0000 Received: from localhost ([127.0.0.1]:49725 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ohwCJ-0002I7-3x for submit@debbugs.gnu.org; Mon, 10 Oct 2022 13:04:14 -0400 Received: from knopi.disroot.org ([178.21.23.139]:44536) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ohwCF-0002Hq-Mz for 56961@debbugs.gnu.org; Mon, 10 Oct 2022 13:04:10 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id A76A64C981; Mon, 10 Oct 2022 19:04:05 +0200 (CEST) X-Virus-Scanned: SPAM Filter at disroot.org Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with UTF8SMTP id B10XojfWUsR6; Mon, 10 Oct 2022 19:04:04 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1665421035; bh=fJ/HZ6b5dLZpWP+tWMGPtzBOs9ic+1AnKCAvRZnIqHU=; h=From:To:Cc:Subject:Date; b=H0Xqxxfcu0aS77rWHp4I6P/AfOUATCpalk0TcfiR/enNKOWUj84ggpC1cGINzajO7 1lb2PGeTmJHut2GuymtcSpqnnLvCPMXsfMWfzmoNUqRszSNoc07794oZN4jaQmU9Aa 1V8//P7Hrg0tnWi+5kI9StmDfMWvQDiCE1Stba+Ol/YNTYqeN+d3L6O53Nr5kTLHI+ PKsM1MMaXDic1K+hJEHiEghpA7nM60QEfUxQAo5cdJbJtdmoVaZ9EMSSAFe+SoqbmP fdpoRsnLJFumcyXy66DFdcEqHzgwXBtjoKUZcPcvCwHbnm1d0A1rDojqyUJx9gxvOm OKAZxrhl/FMyw== Date: Mon, 10 Oct 2022 17:57:06 +0100 Message-Id: <20221010165709.22638-1-paren@disroot.org> Mime-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" Reply-to: "\(" X-ACL-Warn: , "\( via Guix-patches" X-Patchwork-Original-From: "\( via Guix-patches" via From: "\\(" X-getmail-retrieved-from-mailbox: Patches * gnu/packages/golang.scm (go-github-com-delthas-tcell): New variable. --- gnu/packages/golang.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index 7dd3d4d501..cce9c09ca8 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -6085,6 +6085,32 @@ (define-public go-github-com-gdamore-tcell-v2 (modify-inputs (package-inputs go-github-com-gdamore-tcell) (prepend go-golang-org-x-term go-golang-org-x-sys))))) +(define-public go-github-com-delthas-tcell + (package + (inherit go-github-com-gdamore-tcell-v2) + (name "go-github-com-delthas-tcell") + (version "v2.4.1-0.20220223131437-2362f49a2b6c") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/delthas/tcell") + (commit (go-version->git-ref version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "04mai0gicllhjqv7p0i29cdf9myzl8q5h672bdhmid7lv3x1k32f")))) + (arguments + (list #:import-path "github.com/gdamore/tcell/v2")) + (inputs (list)) + (propagated-inputs + (list go-github-com-gdamore-encoding + go-github-com-lucasb-eyer-go-colorful + go-github-com-mattn-go-runewidth + go-golang-org-x-sys + go-golang-org-x-term + go-golang-org-x-text)) + (home-page "https://github.com/delthas/tcell"))) + (define-public go-github-com-rivo-tview (package (name "go-github-com-rivo-tview") From patchwork Mon Oct 10 16:57:07 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\\(" X-Patchwork-Id: 43307 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id DACE527BBEA; Mon, 10 Oct 2022 18:19:08 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 9DBF327BBE9 for ; Mon, 10 Oct 2022 18:19:08 +0100 (BST) Received: from localhost ([::1]:50712 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ohwQl-0006qI-Mz for patchwork@mira.cbaines.net; Mon, 10 Oct 2022 13:19:07 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42338) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ohwD8-0004u1-Tb for guix-patches@gnu.org; Mon, 10 Oct 2022 13:05:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:50655) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ohwD8-0000ja-A9 for guix-patches@gnu.org; Mon, 10 Oct 2022 13:05:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ohwD7-0002Jz-W3 for guix-patches@gnu.org; Mon, 10 Oct 2022 13:05:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#56961] [PATCH v2 2/4] gnu: packages: Add go-mvdan-cc-xurls. Resent-From: "(" Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 10 Oct 2022 17:05:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 56961 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 56961@debbugs.gnu.org Cc: "\(" Received: via spool by 56961-submit@debbugs.gnu.org id=B56961.16654214578844 (code B ref 56961); Mon, 10 Oct 2022 17:05:01 +0000 Received: (at 56961) by debbugs.gnu.org; 10 Oct 2022 17:04:17 +0000 Received: from localhost ([127.0.0.1]:49728 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ohwCM-0002IN-5W for submit@debbugs.gnu.org; Mon, 10 Oct 2022 13:04:16 -0400 Received: from knopi.disroot.org ([178.21.23.139]:45398) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ohwCH-0002Hx-6P for 56961@debbugs.gnu.org; Mon, 10 Oct 2022 13:04:11 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id 6FB7E4CAAD; Mon, 10 Oct 2022 19:04:08 +0200 (CEST) X-Virus-Scanned: SPAM Filter at disroot.org Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with UTF8SMTP id s4vcDMe64I72; Mon, 10 Oct 2022 19:04:06 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1665421035; bh=iZH4Pae5dEFju6MXbew47E6AWgXdpRrSfJ/J1v4EVEI=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=Sz26io/cTXSwwm9gwWKrL439D7WutxKcHBrTGCYASP9H9LQonfs6aJYCReUz9DvDO EMsO2wEXhTByIU4diHggqEssv/OpWcgMWe2Vt8GMe+kQLL+UQTk3gaYkTb4L2+oFtC xtyxTPPZ+Trhs77jsaHXVtauMoyfeP9WayRWC486HQhGmuRNF6RxiMqwJnPnLnQpum BIR0uw5lRpJ3XJyn6BudTWMVQhBcJdlW8GZVJAHM5V9u7hIll2dq4QN+kTx4kC4q7e k0MVWk6VNDbIaMgVA07j0kJmyUC1TfvcnK1sN9GJGhPqdw+zHMQmHC5lf4mNDByoyV OHIzF8CB3IAAg== Date: Mon, 10 Oct 2022 17:57:07 +0100 Message-Id: <20221010165709.22638-2-paren@disroot.org> In-Reply-To: <20221010165709.22638-1-paren@disroot.org> References: <20221010165709.22638-1-paren@disroot.org> Mime-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" Reply-to: "\(" X-ACL-Warn: , "\( via Guix-patches" X-Patchwork-Original-From: "\( via Guix-patches" via From: "\\(" X-getmail-retrieved-from-mailbox: Patches * gnu/packages/golang.scm (go-mvdan-cc-xurls): New variable. --- gnu/packages/golang.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index cce9c09ca8..3455861d33 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -11206,6 +11206,31 @@ (define-public go-github-com-onsi-ginkgo Gomega matcher library.") (license license:expat))) +(define-public go-mvdan-cc-xurls + (package + (name "go-mvdan-cc-xurls") + (version "2.4.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/mvdan/xurls") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0b040nbk1vwlk1qljavh8w8fn2r243q700n6gr8j2asmnz0xq84p")))) + (build-system go-build-system) + (arguments (list #:import-path "mvdan.cc/xurls/v2")) + (propagated-inputs + (list go-golang-org-x-sync + go-github-com-rogpeppe-go-internal)) + (home-page "https://mvdan.cc/xurls/v2") + (synopsis "Extract URLs from text in Go") + (description + "This package provides a library for extracting URLs from plain text +using regular expressions in Go.") + (license license:bsd-3))) + ;;; ;;; Avoid adding new packages to the end of this file. To reduce the chances ;;; of a merge conflict, place them above by existing packages with similar From patchwork Mon Oct 10 16:57:08 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "\\(" X-Patchwork-Id: 43308 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 0C2A927BBEA; Mon, 10 Oct 2022 18:28:32 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id A3F9E27BBE9 for ; Mon, 10 Oct 2022 18:28:31 +0100 (BST) Received: from localhost ([::1]:59352 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ohwZp-0006bT-RQ for patchwork@mira.cbaines.net; Mon, 10 Oct 2022 13:28:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42336) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ohwD8-0004u0-Qn for guix-patches@gnu.org; Mon, 10 Oct 2022 13:05:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:50656) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ohwD8-0000jb-Gl for guix-patches@gnu.org; Mon, 10 Oct 2022 13:05:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ohwD8-0002K7-Bo for guix-patches@gnu.org; Mon, 10 Oct 2022 13:05:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#56961] [PATCH v2 3/4] gnu: packages: Add senpai. Resent-From: "(" Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 10 Oct 2022 17:05:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 56961 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 56961@debbugs.gnu.org Cc: "\(" Received: via spool by 56961-submit@debbugs.gnu.org id=B56961.16654214598853 (code B ref 56961); Mon, 10 Oct 2022 17:05:02 +0000 Received: (at 56961) by debbugs.gnu.org; 10 Oct 2022 17:04:19 +0000 Received: from localhost ([127.0.0.1]:49730 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ohwCO-0002IY-Tg for submit@debbugs.gnu.org; Mon, 10 Oct 2022 13:04:19 -0400 Received: from knopi.disroot.org ([178.21.23.139]:46088) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ohwCI-0002I0-Tp for 56961@debbugs.gnu.org; Mon, 10 Oct 2022 13:04:13 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id 3E4664CB91; Mon, 10 Oct 2022 19:04:10 +0200 (CEST) X-Virus-Scanned: SPAM Filter at disroot.org Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with UTF8SMTP id 2gLRkonGcrZg; Mon, 10 Oct 2022 19:04:08 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1665421035; bh=PSEMA7uFUUPY59z5jFvoXwaFroROQf86KnHUP5aaiMo=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=GxVYuGea+xBDvofrSFZezJ6RD4L9TO0g7Aqko4WNcG5J6HbryrSJOXA/Jql5zq5sh cuIeUBHSsgZyaFsvVDlDNIMmijAWoTqENXZqOqqQuHWZfiXXmedPWcc9S8UgokxqVF RxIxOu8Vlv+KbKKPxizhma0kpw7bn1ep/dsS/YUkIFU5D9H3DHcUTOtJ/Qfhyn3SJI hTTLasCd7hxbNd5v4T3VbElLrkPH+6KtKEVLu1dzyJpUi3UWDlu1lvmB5NuhD7K1Xr FxQ+yYqqSPVJK7fP4JYIa0lq+oabyiCv4FUxMAqgcI1CV9ck5syqN2EBtgZpdJXzCS 5Ok5NCSPZAW9A== Date: Mon, 10 Oct 2022 17:57:08 +0100 Message-Id: <20221010165709.22638-3-paren@disroot.org> In-Reply-To: <20221010165709.22638-1-paren@disroot.org> References: <20221010165709.22638-1-paren@disroot.org> Mime-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" Reply-to: "\(" X-ACL-Warn: , "\( via Guix-patches" X-Patchwork-Original-From: "\( via Guix-patches" via From: "\\(" X-getmail-retrieved-from-mailbox: Patches * gnu/packages/irc.scm (senpai): New variable. --- gnu/packages/irc.scm | 48 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) diff --git a/gnu/packages/irc.scm b/gnu/packages/irc.scm index b82210081c..b64932310b 100644 --- a/gnu/packages/irc.scm +++ b/gnu/packages/irc.scm @@ -12,6 +12,7 @@ ;;; Copyright © 2020 Brett Gilio ;;; Copyright © 2021 WinterHound ;;; Copyright © 2022 Jai Vetrivelan +;;; Copyright © 2022 ( ;;; ;;; This file is part of GNU Guix. ;;; @@ -38,6 +39,7 @@ (define-module (gnu packages irc) #:use-module (guix utils) #:use-module (guix build-system cmake) #:use-module (guix build-system gnu) + #:use-module (guix build-system go) #:use-module (guix build-system meson) #:use-module (guix build-system python) #:use-module (guix build-system qt) @@ -61,10 +63,12 @@ (define-module (gnu packages irc) #:use-module (gnu packages glib) #:use-module (gnu packages gnome) #:use-module (gnu packages gnupg) + #:use-module (gnu packages golang) #:use-module (gnu packages gtk) #:use-module (gnu packages guile) #:use-module (gnu packages lua) #:use-module (gnu packages lxqt) + #:use-module (gnu packages man) #:use-module (gnu packages ncurses) #:use-module (gnu packages openldap) #:use-module (gnu packages kde) @@ -688,3 +692,47 @@ (define-public inspircd server written in C++ for Unix-like operating systems.") (home-page "https://www.inspircd.org/") (license license:gpl2))) + +(define-public senpai + (package + (name "senpai") + (version "0.1.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://git.sr.ht/~taiite/senpai") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1g3fpchjl859xl529wwdx8l0m88ji813mphmh316shdkm09ff160")))) + (build-system go-build-system) + (arguments + (list #:import-path "git.sr.ht/~taiite/senpai" + #:install-source? #f + #:phases + #~(modify-phases %standard-phases + (replace 'build + (lambda* (#:key import-path #:allow-other-keys) + (invoke "make" "-C" (string-append "src/" import-path)))) + (replace 'install + (lambda* (#:key import-path #:allow-other-keys) + (invoke "make" "install" "-C" + (string-append "src/" import-path) + (string-append "PREFIX=" #$output))))))) + (native-inputs (list scdoc)) + (propagated-inputs + (list go-github-com-delthas-tcell + go-mvdan-cc-xurls + go-golang-org-x-time + go-golang-org-x-term + go-golang-org-x-net + go-github-com-mattn-go-runewidth + go-git-sr-ht-emersion-go-scfg)) + (home-page "https://git.sr.ht/~taiite/senpai") + (synopsis "IRC client that works best with bouncers") + (description + "@code{senpai} is an IRC client that works best with bouncers. No logs +are kept, history is fetched from the server via @code{CHATHISTORY}, and +networks are fetched via @code{bouncer-networks}.") + (license license:isc))) From patchwork Mon Oct 10 16:57:09 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "\\(" X-Patchwork-Id: 43306 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 822C427BBEA; Mon, 10 Oct 2022 18:11:57 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 993B927BBE9 for ; Mon, 10 Oct 2022 18:11:56 +0100 (BST) Received: from localhost ([::1]:43748 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ohwJn-0000A3-PF for patchwork@mira.cbaines.net; Mon, 10 Oct 2022 13:11:55 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42342) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ohwD9-0004ui-A6 for guix-patches@gnu.org; Mon, 10 Oct 2022 13:05:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:50657) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ohwD8-0000lN-Vl for guix-patches@gnu.org; Mon, 10 Oct 2022 13:05:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ohwD8-0002KG-R5 for guix-patches@gnu.org; Mon, 10 Oct 2022 13:05:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#56961] [PATCH v2 4/4] gnu: Add home-senpai-service-type. Resent-From: "(" Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 10 Oct 2022 17:05:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 56961 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 56961@debbugs.gnu.org Cc: "\(" Received: via spool by 56961-submit@debbugs.gnu.org id=B56961.16654214628863 (code B ref 56961); Mon, 10 Oct 2022 17:05:02 +0000 Received: (at 56961) by debbugs.gnu.org; 10 Oct 2022 17:04:22 +0000 Received: from localhost ([127.0.0.1]:49732 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ohwCR-0002Ip-IN for submit@debbugs.gnu.org; Mon, 10 Oct 2022 13:04:22 -0400 Received: from knopi.disroot.org ([178.21.23.139]:46752) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ohwCL-0002IF-1V for 56961@debbugs.gnu.org; Mon, 10 Oct 2022 13:04:16 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id 5EEBA4CAAD; Mon, 10 Oct 2022 19:04:12 +0200 (CEST) X-Virus-Scanned: SPAM Filter at disroot.org Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with UTF8SMTP id QGhqWKqNRKFq; Mon, 10 Oct 2022 19:04:10 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1665421035; bh=2SZA+UBkDBm4Fu49T/NjvfWFoKihiOLVFz2uJ45sYk8=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=bET6Bg/l2UpG+oDvWUvF++CYf4lGfCLBZi2UyY6/135vYDK014sx1jgaBYvGvSWNB tjch9ujPlZ72WblkxrSES38Ngc3pRGBO/gQtBgmKiu7NPu/24vdrArHa6rIjmHC4ji Rq6le4JW0b+pIpk/mzB4EytO8jaqyciYcZy5qgiQYpmkYZoUX75ZaEiBaD6N3LDlx0 8uHfKKpMJNlEzzWKwG1IUb9kvvzkGyCyF2g3MCDsYZhNkRdwgwzWJZzbMCZaZsj6uo U1cgMbThmgm5cVm/sD9x64+jcOY2VYbw8SPoUqkE+l18seSRb3FT26u1T0kF3z7S+I 077/VAhBxiq/Q== Date: Mon, 10 Oct 2022 17:57:09 +0100 Message-Id: <20221010165709.22638-4-paren@disroot.org> In-Reply-To: <20221010165709.22638-1-paren@disroot.org> References: <20221010165709.22638-1-paren@disroot.org> Mime-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" Reply-to: "\(" X-ACL-Warn: , "\( via Guix-patches" X-Patchwork-Original-From: "\( via Guix-patches" via From: "\\(" X-getmail-retrieved-from-mailbox: Patches * gnu/local.mk: Add gnu/home/services/irc.scm. * gnu/home/services/irc.scm (home-senpai-configuration): New record type. (home-senpai-service-type): New variable. * doc/guix.texi ("Home Configuration")["Home Services"]: Document them. --- doc/guix.texi | 87 +++++++++++++++++++++ gnu/home/services/irc.scm | 154 ++++++++++++++++++++++++++++++++++++++ gnu/local.mk | 1 + 3 files changed, 242 insertions(+) create mode 100644 gnu/home/services/irc.scm diff --git a/doc/guix.texi b/doc/guix.texi index 14592142dd..f62d84c6e9 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -40363,6 +40363,7 @@ services)}. * Essential Home Services:: Environment variables, packages, on-* scripts. * Shells: Shells Home Services. POSIX shells, Bash, Zsh. * Mcron: Mcron Home Service. Scheduled User's Job Execution. +* IRC: IRC Home Services. Services for Internet Relay Chat. * Power Management: Power Management Home Services. Services for battery power. * Shepherd: Shepherd Home Service. Managing User's Daemons. * SSH: Secure Shell. Setting up the secure shell client. @@ -40815,6 +40816,92 @@ specifications,, mcron, GNU@tie{}mcron}). @end table @end deftp +@node IRC Home Services +@subsection IRC Home Services + +@cindex irc +@cindex messaging +The @code{(gnu home services irc)} module provides home services for +Internet Relay Chat-related programs. + +@defvr {Scheme Variable} home-senpai-service-type +Service for configuration of @code{senpai}, a terminal-based IRC client +that works best with network bouncers such as @code{znc} and @code{soju}. +@end defvr + +@deftp {Data Type} home-senpai-configuration +Data type representing the configuration of the +@code{home-senpai-service-type}. + +@table @asis +@item @code{address} +The address of the IRC server to connect to. + +@item @code{nickname} +A string to use as the IRC nickname. + +@item @code{username} (default: @code{#f}) +A string to use as the IRC username. + +@item @code{realname} (default: @code{#f}) +A string to use as the IRC real name. + +@item @code{password} +Either a string to use as the IRC password, or a list of strings +and file-like objects representing a command line that prints the +password to standard output. + +@item @code{channels} (default: @code{#f}) +A list of channels to connect to by default. + +@item @code{highlight-words} (default: @code{#f}) +A list of words that, when said by another user, will cause you to +be ``highlighted'', as if you were mentioned. + +@item @code{highlight-beep?} (default: @code{#f}) +Whether to make a sound when you are ``highlighted''. + +@item @code{highlight-script} (default: @code{#f}) +A file-like object representing a shell script to be run when you +are ``highlighted''. State information is passed to the script via +the environment; see @command{man senpai.5} for the list of +variables passed to the script. + +@item @code{nicknames-width} (default: @code{14}) +The width of the pane containing the nicknames corresponding to +each message. + +@item @code{channels-width} (default: @code{16}) +The width of the pane containing the list of channels. + +@item @code{members-width} (default: @code{16}) +The width of the pane containing the list of channel members. + +@item @code{message-width} (default: @code{0}) +The width of the messages. + +@item @code{tls?} (default: @code{#t}) +Whether to enable TLS connection support. + +@item @code{typing-notify?} (default: @code{#t}) +Whether to send typing notifications to others. + +@item @code{mouse?} (default: @code{#t}) +Whether to enable mouse interaction. + +@item @code{prompt-color} (default: @code{-1}) +The foreground colour (either an ANSI colour code number or a +hexadecimal colour string) to use for the ``>'' in the message +prompt. + +@item @code{unread-color} (default: @code{-1}) +The foreground colour to use for buffers with unread messages. + +@item @code{debug?} (default: @code{#f}) +Whether to print debugging information to the home message buffer. +@end table +@end deftp + @node Power Management Home Services @subsection Power Management Home Services diff --git a/gnu/home/services/irc.scm b/gnu/home/services/irc.scm new file mode 100644 index 0000000000..1097f9a5f0 --- /dev/null +++ b/gnu/home/services/irc.scm @@ -0,0 +1,154 @@ +;;; GNU Guix --- Functional package management for GNU +;;; Copyright © 2022 ( +;;; +;;; 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 irc) + #:use-module (gnu home services) + #:use-module (guix gexp) + #:use-module (guix packages) + #:use-module (guix records) + #:use-module (srfi srfi-1) + #:use-module (srfi srfi-26) + + #:export (home-senpai-service-type + home-senpai-configuration)) + +;;; Commentary: +;;; +;;; This module contains home services for Internet Relay Chat. +;;; +;;; Code: + + +;;; +;;; Senpai. +;;; + +(define-record-type* + home-senpai-configuration make-home-senpai-configuration + home-senpai-configuration? + (address home-senpai-address) ;string + (nickname home-senpai-nickname) ;string + (username home-senpai-username ;string | #f + (default #f)) + (realname home-senpai-realname ;string | #f + (default #f)) + (password home-senpai-password) ;string | file-like, list of string + (channels home-senpai-channels ;list of string | #f + (default #f)) + (highlight-words home-senpai-highlight-words ;list of string | #f + (default #f)) + (highlight-beep? home-senpai-highlight-beep? ;boolean + (default #f)) + (highlight-script home-senpai-highlight-script ;file-like | #f + (default #f)) + (nicknames-width home-senpai-nicknames-width ;integer + (default 14)) + (channels-width home-senpai-channels-width ;integer + (default 16)) + (members-width home-senpai-members-width ;integer + (default 16)) + (message-width home-senpai-message-width ;integer + (default 0)) + (tls? home-senpai-tls? ;boolean + (default #t)) + (typing-notify? home-senpai-typing-notify? ;boolean + (default #t)) + (mouse? home-senpai-mouse? ;boolean + (default #t)) + (prompt-color home-senpai-prompt-color ;integer | string + (default -1)) + (unread-color home-senpai-unread-color ;integer | string + (default -1)) + (debug? home-senpai-debug? ;boolean + (default #f))) + +(define (home-senpai-xdg-configuration-files config) + (define (string-field name field) + (let ((value (field config))) + (if value + (list name " \"" value "\"\n") + '()))) + + (define (string-list-field name field) + (let ((value (field config))) + (if value + (append (list name) + (concatenate (map (cute list " \"" <> "\"") value)) + (list "\n")) + '()))) + + (define (integer-field name field) + (let ((value (field config))) + (if value + (list name " " (number->string value) "\n") + '()))) + + (define (colour-field name field) + (let ((value (field config))) + (if (string? value) + (string-field name (compose (cute string-append "#" <>) + field)) + (integer-field name field)))) + + (define (boolean-field name field) + (let ((value (field config))) + (list name " " (if value "true" "false") "\n"))) + + (define (symbol-field name field) + (string-field name (compose symbol->string field))) + + (define* (record-field name #:rest fields) + (append (list name " {\n") + (concatenate fields) + (list "}\n"))) + + `(("senpai/sen.scfg" + ,(apply mixed-text-file "senpai.scfg" + (append (string-field "address" home-senpai-address) + (string-field "nickname" home-senpai-nickname) + (string-field "username" home-senpai-username) + (string-field "realname" home-senpai-realname) + (if (list? (home-senpai-password config)) + (string-list-field "password-cmd" home-senpai-password) + (string-field "password" home-senpai-password)) + (string-list-field "channel" home-senpai-channels) + (string-list-field "highlight" home-senpai-highlight-words) + (boolean-field "on-highlight-beep" home-senpai-highlight-beep?) + (string-field "on-highlight-path" home-senpai-highlight-script) + (record-field "pane-widths" + (integer-field "nicknames" home-senpai-nicknames-width) + (integer-field "channels" home-senpai-channels-width) + (integer-field "members" home-senpai-members-width) + (integer-field "text" home-senpai-message-width)) + (boolean-field "tls" home-senpai-tls?) + (boolean-field "typings" home-senpai-typing-notify?) + (boolean-field "mouse" home-senpai-mouse?) + (record-field "colors" + (colour-field "prompt" home-senpai-prompt-color) + (colour-field "unread" home-senpai-unread-color)) + (boolean-field "debug" home-senpai-debug?)))))) + +(define home-senpai-service-type + (service-type + (name 'home-senpai) + (extensions + (list (service-extension home-xdg-configuration-files-service-type + home-senpai-xdg-configuration-files))) + (description + "Configure senpai, a terminal-based IRC client designed for use +with bouncers."))) diff --git a/gnu/local.mk b/gnu/local.mk index 9a1aad300e..3bb4f2a353 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -90,6 +90,7 @@ GNU_SYSTEM_MODULES = \ %D%/home/services/symlink-manager.scm \ %D%/home/services/fontutils.scm \ %D%/home/services/guix.scm \ + %D%/home/services/irc.scm \ %D%/home/services/pm.scm \ %D%/home/services/shells.scm \ %D%/home/services/shepherd.scm \