* [bug#56961] [PATCHSET] Add senpai @ 2022-08-03 21:16 ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 1/6] gnu: packages: Add go-github-com-lucasb-eyer-go-colorful ( via Guix-patches via ` (3 more replies) 0 siblings, 4 replies; 13+ messages in thread From: ( via Guix-patches via @ 2022-08-03 21:16 UTC (permalink / raw) To: 56961 This patchset adds the Senpai <https://git.sr.ht/~taiite/senpai> IRC client, along with its prerequisites. Note: This patchset includes packages that already exist in certain other patchsets: go-github-com-lucasb-eyer-go-colorful: #55903 go-github-com-google-shlex: #47539, #54882, #55903 go-git-sr-ht--emersion-go-scfg: #54882 Such is the nature of Go... :( ( (6): gnu: packages: Add go-github-com-lucasb-eyer-go-colorful. gnu: packages: Add go-github-com-delthas-tcell. gnu: packages: Add go-mvdan-cc-xurls. gnu: packages: Add go-github-com-google-shlex. gnu: packages: Add go-git-sr-ht--emersion-go-scfg. gnu: packages: Add senpai. -- ( ^ permalink raw reply [flat|nested] 13+ messages in thread
* [bug#56961] [PATCH 1/6] gnu: packages: Add go-github-com-lucasb-eyer-go-colorful. 2022-08-03 21:16 [bug#56961] [PATCHSET] Add senpai ( via Guix-patches via @ 2022-08-03 21:18 ` ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 2/6] gnu: packages: Add go-github-com-delthas-tcell ( via Guix-patches via ` (4 more replies) 2022-10-10 16:57 ` [bug#56961] [PATCH v2 1/4] gnu: packages: Add go-github-com-delthas-tcell ( via Guix-patches via ` (2 subsequent siblings) 3 siblings, 5 replies; 13+ messages in thread From: ( via Guix-patches via @ 2022-08-03 21:18 UTC (permalink / raw) To: 56961; +Cc: ( * gnu/packages/golang.scm (go-github-com-lucasb-eyer-go-colorful): 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 1ce55875d8..8962d18b3e 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -35,6 +35,7 @@ ;;; Copyright © 2021 Lu Hui <luhux76@gmail.com> ;;; Copyright © 2022 Pier-Hugues Pellerin <phpellerin@gmail.com> ;;; Copyright © 2022 muradm <mail@muradm.net> +;;; Copyright © 2022 ( <paren@disroot.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -9891,3 +9892,28 @@ (define-public go-github-com-sourcegraph-jsonrpc2 (description "Package jsonrpc2 provides a Go implementation of JSON-RPC 2.0.") (license license:expat))) + +(define-public go-github-com-lucasb-eyer-go-colorful + (package + (name "go-github-com-lucasb-eyer-go-colorful") + (version "1.2.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/lucasb-eyer/go-colorful") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "08c3fkf27r16izjjd4w94xd1z7w1r4mdalbl53ms2ka2j465s3qs")))) + (build-system go-build-system) + (propagated-inputs (list go-golang-org-x-image)) + (arguments + (list #:import-path "github.com/lucasb-eyer/go-colorful")) + (home-page "https://github.com/lucasb-eyer/go-colorful") + (synopsis "Library for manipulating colors in Go") + (description + "This package provides a library for manipulating colors in Go. +It stores colors in RGB and provides methods for converting them to +other color-spaces.") + (license license:expat))) -- 2.37.1 ^ permalink raw reply related [flat|nested] 13+ messages in thread
* [bug#56961] [PATCH 2/6] gnu: packages: Add go-github-com-delthas-tcell. 2022-08-03 21:18 ` [bug#56961] [PATCH 1/6] gnu: packages: Add go-github-com-lucasb-eyer-go-colorful ( via Guix-patches via @ 2022-08-03 21:18 ` ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 3/6] gnu: packages: Add go-mvdan-cc-xurls ( via Guix-patches via ` (3 subsequent siblings) 4 siblings, 0 replies; 13+ messages in thread From: ( via Guix-patches via @ 2022-08-03 21:18 UTC (permalink / raw) To: 56961; +Cc: ( * 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 8962d18b3e..34b9853a2e 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -9917,3 +9917,29 @@ (define-public go-github-com-lucasb-eyer-go-colorful It stores colors in RGB and provides methods for converting them to other color-spaces.") (license license:expat))) + +(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"))) -- 2.37.1 ^ permalink raw reply related [flat|nested] 13+ messages in thread
* [bug#56961] [PATCH 3/6] gnu: packages: Add go-mvdan-cc-xurls. 2022-08-03 21:18 ` [bug#56961] [PATCH 1/6] gnu: packages: Add go-github-com-lucasb-eyer-go-colorful ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 2/6] gnu: packages: Add go-github-com-delthas-tcell ( via Guix-patches via @ 2022-08-03 21:18 ` ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 4/6] gnu: packages: Add go-github-com-google-shlex ( via Guix-patches via ` (2 subsequent siblings) 4 siblings, 0 replies; 13+ messages in thread From: ( via Guix-patches via @ 2022-08-03 21:18 UTC (permalink / raw) To: 56961; +Cc: ( * 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 34b9853a2e..13dc28ddc6 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -9943,3 +9943,28 @@ (define-public go-github-com-delthas-tcell go-golang-org-x-term go-golang-org-x-text)) (home-page "https://github.com/delthas/tcell"))) + +(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))) -- 2.37.1 ^ permalink raw reply related [flat|nested] 13+ messages in thread
* [bug#56961] [PATCH 4/6] gnu: packages: Add go-github-com-google-shlex. 2022-08-03 21:18 ` [bug#56961] [PATCH 1/6] gnu: packages: Add go-github-com-lucasb-eyer-go-colorful ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 2/6] gnu: packages: Add go-github-com-delthas-tcell ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 3/6] gnu: packages: Add go-mvdan-cc-xurls ( via Guix-patches via @ 2022-08-03 21:18 ` ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 5/6] gnu: packages: Add go-git-sr-ht--emersion-go-scfg ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 6/6] gnu: packages: Add senpai ( via Guix-patches via 4 siblings, 0 replies; 13+ messages in thread From: ( via Guix-patches via @ 2022-08-03 21:18 UTC (permalink / raw) To: 56961; +Cc: ( * gnu/packages/golang.scm (go-github-com-google-shlex): New variable. --- gnu/packages/golang.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index 13dc28ddc6..90cd1849fd 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -9968,3 +9968,27 @@ (define-public go-mvdan-cc-xurls "This package provides a library for extracting URLs from plain text using regular expressions in Go.") (license license:bsd-3))) + +(define-public go-github-com-google-shlex + (let ((commit "c34317bd91bf98fab745d77b03933cf8769299fe") + (revision "0")) + (package + (name "go-github-com-google-shlex") + (version "1.2.1") + (source (origin + (method git-fetch) + (uri (git-reference + (url "github.com/google/shlex") + (commit commit))) + (file-name (git-file-name name commit)) + (sha256 + (base32 + "00qivza4hkllfkar2vpqmyxybi0fwqipgijv61dgapq4xddxdq0r")))) + (build-system go-build-system) + (arguments (list #:import-path "github.com/google/shlex")) + (home-page "github.com/google/shlex") + (synopsis "Simple shell lexer for Go") + (description + "Shlex is a simple shell-syntax lexer for Go that supports +quoting, commenting, and escaping.") + (license license:asl2.0)))) -- 2.37.1 ^ permalink raw reply related [flat|nested] 13+ messages in thread
* [bug#56961] [PATCH 5/6] gnu: packages: Add go-git-sr-ht--emersion-go-scfg. 2022-08-03 21:18 ` [bug#56961] [PATCH 1/6] gnu: packages: Add go-github-com-lucasb-eyer-go-colorful ( via Guix-patches via ` (2 preceding siblings ...) 2022-08-03 21:18 ` [bug#56961] [PATCH 4/6] gnu: packages: Add go-github-com-google-shlex ( via Guix-patches via @ 2022-08-03 21:18 ` ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 6/6] gnu: packages: Add senpai ( via Guix-patches via 4 siblings, 0 replies; 13+ messages in thread From: ( via Guix-patches via @ 2022-08-03 21:18 UTC (permalink / raw) To: 56961; +Cc: ( * gnu/packages/golang.scm (go-git-sr-ht--emersion-go-scfg): 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 90cd1849fd..38a07bc647 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -9992,3 +9992,28 @@ (define-public go-github-com-google-shlex "Shlex is a simple shell-syntax lexer for Go that supports quoting, commenting, and escaping.") (license license:asl2.0)))) + +(define-public go-git-sr-ht--emersion-go-scfg + (package + (name "go-git-sr-ht--emersion-go-scfg") + (version "0.0.0-20211215104734-c2c7a15d6c99") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://git.sr.ht/~emersion/go-scfg") + (commit (go-version->git-ref version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "02gn8hz8zfv8y0krysx2wv951gw8hmhdfqf1ysidwm7i293365w4")))) + (build-system go-build-system) + (arguments (list #:import-path "git.sr.ht/~emersion/go-scfg")) + (propagated-inputs + (list go-github-com-google-shlex + go-github-com-davecgh-go-spew)) + (home-page "https://git.sr.ht/~emersion/go-scfg") + (synopsis "SCFG parser for Go") + (description + "This package provides a @acronym{SCFG, Simple Configuration} +parsing library for Go.") + (license license:expat))) -- 2.37.1 ^ permalink raw reply related [flat|nested] 13+ messages in thread
* [bug#56961] [PATCH 6/6] gnu: packages: Add senpai. 2022-08-03 21:18 ` [bug#56961] [PATCH 1/6] gnu: packages: Add go-github-com-lucasb-eyer-go-colorful ( via Guix-patches via ` (3 preceding siblings ...) 2022-08-03 21:18 ` [bug#56961] [PATCH 5/6] gnu: packages: Add go-git-sr-ht--emersion-go-scfg ( via Guix-patches via @ 2022-08-03 21:18 ` ( via Guix-patches via 4 siblings, 0 replies; 13+ messages in thread From: ( via Guix-patches via @ 2022-08-03 21:18 UTC (permalink / raw) To: 56961; +Cc: ( * gnu/packages/irc.scm (senpai): New variable. --- gnu/packages/irc.scm | 61 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) diff --git a/gnu/packages/irc.scm b/gnu/packages/irc.scm index efb32a39e0..3684e02e32 100644 --- a/gnu/packages/irc.scm +++ b/gnu/packages/irc.scm @@ -12,6 +12,7 @@ ;;; Copyright © 2020 Brett Gilio <brettg@gnu.org> ;;; Copyright © 2021 WinterHound <winterhound@yandex.com> ;;; Copyright © 2022 Jai Vetrivelan <jaivetrivelan@gmail.com> +;;; Copyright © 2022 ( <paren@disroot.org> ;;; ;;; 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,60 @@ (define-public inspircd server written in C++ for Unix-like operating systems.") (home-page "https://www.inspircd.org/") (license license:gpl2))) + +(define-public senpai + (let ((commit "e8ed8e7e13134ee7fc8ac116d58efc55813632a1") + (revision "2")) + (package + (name "senpai") + (version (git-version "0.0.0" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://git.sr.ht/~taiite/senpai") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1rq07ldi8ga5pv9mm0g4sgipqxnnjcff2n1wsmjx3wqcbrmrqhbg")))) + (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)))) + (add-after 'build 'build-docs + (lambda* (#:key import-path #:allow-other-keys) + (with-directory-excursion + (string-append "src/" import-path) + (invoke "sh" "-c" + (string-append "scdoc < doc/senpai.1.scd " + "> doc/senpai.1 && " + "scdoc < doc/senpai.5.scd " + "> doc/senpai.5"))))) + (replace 'install + (lambda* (#:key outputs import-path #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + (invoke "make" "install" "-C" + (string-append "src/" import-path) + (string-append "PREFIX=" out)))))))) + (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 from the server via @code{bouncer-networks}.") + (license license:isc)))) -- 2.37.1 ^ permalink raw reply related [flat|nested] 13+ messages in thread
* [bug#56961] [PATCH v2 1/4] gnu: packages: Add go-github-com-delthas-tcell. 2022-08-03 21:16 [bug#56961] [PATCHSET] Add senpai ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 1/6] gnu: packages: Add go-github-com-lucasb-eyer-go-colorful ( via Guix-patches via @ 2022-10-10 16:57 ` ( via Guix-patches via 2022-10-10 16:57 ` [bug#56961] [PATCH v2 2/4] gnu: packages: Add go-mvdan-cc-xurls ( via Guix-patches via ` (2 more replies) 2023-07-25 17:29 ` [bug#56961] [PATCHSET] Add senpai guix-patches--- via 2024-03-19 22:29 ` bug#56961: " Sharlatan Hellseher 3 siblings, 3 replies; 13+ messages in thread From: ( via Guix-patches via @ 2022-10-10 16:57 UTC (permalink / raw) To: 56961; +Cc: ( * 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") -- 2.38.0 ^ permalink raw reply related [flat|nested] 13+ messages in thread
* [bug#56961] [PATCH v2 2/4] gnu: packages: Add go-mvdan-cc-xurls. 2022-10-10 16:57 ` [bug#56961] [PATCH v2 1/4] gnu: packages: Add go-github-com-delthas-tcell ( via Guix-patches via @ 2022-10-10 16:57 ` ( via Guix-patches via 2022-10-10 16:57 ` [bug#56961] [PATCH v2 3/4] gnu: packages: Add senpai ( via Guix-patches via 2022-10-10 16:57 ` [bug#56961] [PATCH v2 4/4] gnu: Add home-senpai-service-type ( via Guix-patches via 2 siblings, 0 replies; 13+ messages in thread From: ( via Guix-patches via @ 2022-10-10 16:57 UTC (permalink / raw) To: 56961; +Cc: ( * 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 -- 2.38.0 ^ permalink raw reply related [flat|nested] 13+ messages in thread
* [bug#56961] [PATCH v2 3/4] gnu: packages: Add senpai. 2022-10-10 16:57 ` [bug#56961] [PATCH v2 1/4] gnu: packages: Add go-github-com-delthas-tcell ( via Guix-patches via 2022-10-10 16:57 ` [bug#56961] [PATCH v2 2/4] gnu: packages: Add go-mvdan-cc-xurls ( via Guix-patches via @ 2022-10-10 16:57 ` ( via Guix-patches via 2022-10-10 16:57 ` [bug#56961] [PATCH v2 4/4] gnu: Add home-senpai-service-type ( via Guix-patches via 2 siblings, 0 replies; 13+ messages in thread From: ( via Guix-patches via @ 2022-10-10 16:57 UTC (permalink / raw) To: 56961; +Cc: ( * 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 <brettg@gnu.org> ;;; Copyright © 2021 WinterHound <winterhound@yandex.com> ;;; Copyright © 2022 Jai Vetrivelan <jaivetrivelan@gmail.com> +;;; Copyright © 2022 ( <paren@disroot.org> ;;; ;;; 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))) -- 2.38.0 ^ permalink raw reply related [flat|nested] 13+ messages in thread
* [bug#56961] [PATCH v2 4/4] gnu: Add home-senpai-service-type. 2022-10-10 16:57 ` [bug#56961] [PATCH v2 1/4] gnu: packages: Add go-github-com-delthas-tcell ( via Guix-patches via 2022-10-10 16:57 ` [bug#56961] [PATCH v2 2/4] gnu: packages: Add go-mvdan-cc-xurls ( via Guix-patches via 2022-10-10 16:57 ` [bug#56961] [PATCH v2 3/4] gnu: packages: Add senpai ( via Guix-patches via @ 2022-10-10 16:57 ` ( via Guix-patches via 2 siblings, 0 replies; 13+ messages in thread From: ( via Guix-patches via @ 2022-10-10 16:57 UTC (permalink / raw) To: 56961; +Cc: ( * 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 ( <paren@disroot.org> +;;; +;;; 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 <http://www.gnu.org/licenses/>. + +(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: + +\f +;;; +;;; Senpai. +;;; + +(define-record-type* <home-senpai-configuration> + 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 \ -- 2.38.0 ^ permalink raw reply related [flat|nested] 13+ messages in thread
* [bug#56961] [PATCHSET] Add senpai 2022-08-03 21:16 [bug#56961] [PATCHSET] Add senpai ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 1/6] gnu: packages: Add go-github-com-lucasb-eyer-go-colorful ( via Guix-patches via 2022-10-10 16:57 ` [bug#56961] [PATCH v2 1/4] gnu: packages: Add go-github-com-delthas-tcell ( via Guix-patches via @ 2023-07-25 17:29 ` guix-patches--- via 2024-03-19 22:29 ` bug#56961: " Sharlatan Hellseher 3 siblings, 0 replies; 13+ messages in thread From: guix-patches--- via @ 2023-07-25 17:29 UTC (permalink / raw) To: 56961 Didn't see this earlier, but I think my 64222 superseded it. ^ permalink raw reply [flat|nested] 13+ messages in thread
* bug#56961: [PATCHSET] Add senpai 2022-08-03 21:16 [bug#56961] [PATCHSET] Add senpai ( via Guix-patches via ` (2 preceding siblings ...) 2023-07-25 17:29 ` [bug#56961] [PATCHSET] Add senpai guix-patches--- via @ 2024-03-19 22:29 ` Sharlatan Hellseher 3 siblings, 0 replies; 13+ messages in thread From: Sharlatan Hellseher @ 2024-03-19 22:29 UTC (permalink / raw) To: 56961-done [-- Attachment #1: Type: text/plain, Size: 108 bytes --] Senpai was added from <https://issues.guix.gnu.org/64222> Closing this issue as not implemented. -- Oleg [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 832 bytes --] ^ permalink raw reply [flat|nested] 13+ messages in thread
end of thread, other threads:[~2024-03-19 22:30 UTC | newest] Thread overview: 13+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2022-08-03 21:16 [bug#56961] [PATCHSET] Add senpai ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 1/6] gnu: packages: Add go-github-com-lucasb-eyer-go-colorful ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 2/6] gnu: packages: Add go-github-com-delthas-tcell ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 3/6] gnu: packages: Add go-mvdan-cc-xurls ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 4/6] gnu: packages: Add go-github-com-google-shlex ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 5/6] gnu: packages: Add go-git-sr-ht--emersion-go-scfg ( via Guix-patches via 2022-08-03 21:18 ` [bug#56961] [PATCH 6/6] gnu: packages: Add senpai ( via Guix-patches via 2022-10-10 16:57 ` [bug#56961] [PATCH v2 1/4] gnu: packages: Add go-github-com-delthas-tcell ( via Guix-patches via 2022-10-10 16:57 ` [bug#56961] [PATCH v2 2/4] gnu: packages: Add go-mvdan-cc-xurls ( via Guix-patches via 2022-10-10 16:57 ` [bug#56961] [PATCH v2 3/4] gnu: packages: Add senpai ( via Guix-patches via 2022-10-10 16:57 ` [bug#56961] [PATCH v2 4/4] gnu: Add home-senpai-service-type ( via Guix-patches via 2023-07-25 17:29 ` [bug#56961] [PATCHSET] Add senpai guix-patches--- via 2024-03-19 22:29 ` bug#56961: " Sharlatan Hellseher
Code repositories for project(s) associated with this public inbox https://git.savannah.gnu.org/cgit/guix.git This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).