GNU bug report logs - #65976
[PATCH 1/3] gnu: Add ghc-hsyslog.

Previous Next

Package: guix-patches;

Reported by: pinoaffe <pinoaffe <at> gmail.com>

Date: Thu, 14 Sep 2023 10:41:01 UTC

Severity: normal

Tags: patch

To reply to this bug, email your comments to 65976 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#65976; Package guix-patches. (Thu, 14 Sep 2023 10:41:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to pinoaffe <pinoaffe <at> gmail.com>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Thu, 14 Sep 2023 10:41:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: pinoaffe <pinoaffe <at> gmail.com>
To: guix-patches <at> gnu.org
Subject: [PATCH 1/3] gnu: Add ghc-hsyslog.
Date: Thu, 14 Sep 2023 12:39:26 +0200
* gnu/packages/haskell-xyz.scm (ghc-hsyslog): New variable.
---
 gnu/packages/haskell-xyz.scm | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/gnu/packages/haskell-xyz.scm b/gnu/packages/haskell-xyz.scm
index c02fd007f9..6d540aee54 100644
--- a/gnu/packages/haskell-xyz.scm
+++ b/gnu/packages/haskell-xyz.scm
@@ -33,6 +33,7 @@
 ;;; Copyright © 2022 jgart <jgart <at> dismail.de>
 ;;; Copyright © 2023 Josselin Poiret <dev <at> jpoiret.xyz>
 ;;; Copyright © 2023 zamfofex <zamfofex <at> twdb.moe>
+;;; Copyright © 2023 pinoaffe <pinoaffe <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1422,6 +1423,32 @@ (define-public ghc-case-insensitive
 the resulting type will be insensitive to cases.")
     (license license:bsd-3)))
 
+(define-public ghc-hsyslog
+  (package
+    (name "ghc-hsyslog")
+    (version "5.0.2")
+    (source (origin
+              (method url-fetch)
+              (uri (hackage-uri "hsyslog" version))
+              (sha256
+               (base32
+                "1kkypn0dd92aqv8dr112bhkr9k9r9mchnyyvy41kvhj2zg447v1y"))))
+    (build-system haskell-build-system)
+    (properties '((upstream-name . "hsyslog")))
+    (arguments
+     `(#:cabal-revision ("1"
+                         "0k1j46nk3z64zw4bqmvw5lgy16ih200m66rv4b6ygjqv7nglqq0b")))
+    (home-page "https://github.com/peti/hsyslog")
+    (synopsis "FFI interface to syslog(3) from POSIX.1-2008")
+    (description
+     "This package provides a Haskell interface to @code{syslog} as specified
+in POSIX.1-2008.  The entire public API lives in @code{System.Posix.Syslog}.
+There is a set of exposed modules available underneath that one, which contain
+various implementation details that may be useful to other developers who want
+to implement syslog-related functionality.  Users of @code{syslog}, however,
+do not need them.")
+    (license license:bsd-3)))
+
 (define-public ghc-cassava
   (package
     (name "ghc-cassava")

base-commit: cf5cb0875b06b5823e9de8bbd01ddd8c0b0d15a7
-- 
2.41.0





Information forwarded to guix-patches <at> gnu.org:
bug#65976; Package guix-patches. (Thu, 14 Sep 2023 10:44:02 GMT) Full text and rfc822 format available.

Message #8 received at 65976 <at> debbugs.gnu.org (full text, mbox):

From: pinoaffe <pinoaffe <at> gmail.com>
To: 65976 <at> debbugs.gnu.org
Subject: [PATCH 2/3] gnu: Add ghc-twain.
Date: Thu, 14 Sep 2023 12:42:16 +0200
* gnu/packages/haskell-xyz.scm (ghc-twain): New variable.
---
 gnu/packages/haskell-web.scm | 30 ++++++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)

diff --git a/gnu/packages/haskell-web.scm b/gnu/packages/haskell-web.scm
index 75b84b10a7..14cf16681c 100644
--- a/gnu/packages/haskell-web.scm
+++ b/gnu/packages/haskell-web.scm
@@ -13,6 +13,7 @@
 ;;; Copyright © 2020 Alexandru-Sergiu Marton <brown121407 <at> member.fsf.org>
 ;;; Copyright © 2020 Giacomo Leidi <goodoldpaul <at> autistici.org>
 ;;; Copyright © 2022 Alice Brenon <alice.brenon <at> ens-lyon.fr>
+;;; Copyright © 2023 pinoaffe <pinoaffe <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -483,6 +484,35 @@ (define-public ghc-wai
 communication between web applications and web servers.")
     (license license:bsd-3)))
 
+(define-public ghc-twain
+  (package
+    (name "ghc-twain")
+    (version "2.1.2.0")
+    (source (origin
+              (method url-fetch)
+              (uri (hackage-uri "twain" version))
+              (sha256
+               (base32
+                "1hkzp2g671dagmv1qznkf3mw3l2mslckg7h0a8x8633h6i3j6br0"))))
+    (build-system haskell-build-system)
+    (properties '((upstream-name . "twain")))
+    (inputs (list ghc-aeson
+                  ghc-case-insensitive
+                  ghc-cookie
+                  ghc-either
+                  ghc-http-types
+                  ghc-http2
+                  ghc-vault
+                  ghc-wai
+                  ghc-wai-extra))
+    (native-inputs (list ghc-hspec ghc-hspec-discover ghc-hspec-wai))
+    (home-page "https://github.com/alexmingoia/twain#readme")
+    (synopsis "Tiny web application framework for WAI.")
+    (description
+     "Twain is tiny web application framework for WAI. It provides routing, parameter
+parsing, and an either-like monad for composing responses.")
+    (license license:bsd-3)))
+
 (define-public ghc-wai-logger
   (package
     (name "ghc-wai-logger")
-- 
2.41.0





Information forwarded to guix-patches <at> gnu.org:
bug#65976; Package guix-patches. (Thu, 14 Sep 2023 10:44:02 GMT) Full text and rfc822 format available.

Message #11 received at 65976 <at> debbugs.gnu.org (full text, mbox):

From: pinoaffe <pinoaffe <at> gmail.com>
To: 65976 <at> debbugs.gnu.org
Subject: [PATCH 3/3] gnu: Add mailctl.
Date: Thu, 14 Sep 2023 12:43:04 +0200
* gnu/packages/mail.scm (mailctl): New variable.
---
 gnu/packages/mail.scm | 56 +++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 56 insertions(+)

diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
index ecaab1c7cd..a64da6a328 100644
--- a/gnu/packages/mail.scm
+++ b/gnu/packages/mail.scm
@@ -52,6 +52,7 @@
 ;;; Copyright © 2022 jgart <jgart <at> dismail.de>
 ;;; Copyright © 2022 ( <paren <at> disroot.org>
 ;;; Copyright © 2023 Timo Wilken <guix <at> twilken.net>
+;;; Copyright © 2023 pinoaffe <pinoaffe <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -112,6 +113,7 @@ (define-module (gnu packages mail)
   #:use-module (gnu packages guile)
   #:use-module (gnu packages guile-xyz)
   #:use-module (gnu packages haskell-xyz)
+  #:use-module (gnu packages haskell-web)
   #:use-module (gnu packages icu4c)
   #:use-module (gnu packages kerberos)
   #:use-module (gnu packages language)
@@ -176,6 +178,7 @@ (define-module (gnu packages mail)
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system go)
   #:use-module (guix build-system guile)
+  #:use-module (guix build-system haskell)
   #:use-module (guix build-system meson)
   #:use-module (guix build-system perl)
   #:use-module (guix build-system pyproject)
@@ -1145,6 +1148,59 @@ (define-public offlineimap3
 (define-public offlineimap
   (deprecated-package "offlineimap" offlineimap3))
 
+(define-public mailctl
+  (package
+   (name "mailctl")
+   (version "0.8.8")
+   (source (origin
+            (method git-fetch)
+            (uri (git-reference
+                  (url "https://github.com/pdobsan/mailctl")
+                  (commit version)))
+            (file-name (git-file-name name version))
+            (sha256
+             (base32
+              "0zj1hcipb4d42rq3xl9qdx0ra94xlz6572y35m7f9bgkc35plnv8"))))
+   (build-system haskell-build-system)
+   (home-page "https://github.com/pdobsan/mailctl")
+   (arguments `(#:phases (modify-phases %standard-phases
+                           ;; The mailctl.cabal file specifies a minimum cabal
+                           ;; version of 3.8 (which is newer than the cabal
+                           ;; packaged in guix), but doesn't use any new
+                           ;; features and it builds with 3.6.
+                           (add-after 'unpack 'patch-cabal-version
+                             (lambda _
+                               (substitute* "mailctl.cabal"
+                                 (("3.8") "3.6")))))))
+   (inputs (list ghc-aeson
+                 ghc-hsyslog
+                 ghc-http-conduit
+                 ghc-network-uri
+                 ghc-optparse-applicative
+                 ghc-pretty-simple
+                 ghc-twain
+                 ghc-utf8-string
+                 ghc-warp
+                 ghc-yaml))
+   (synopsis "Authorize and renew OAuth2 credentials for IMAP/SMTP clients")
+   (description "@code{mailctl} provides IMAP/SMTP clients with the
+capabilities of renewal and authorization of OAuth2 credentials.
+
+Many IMAP/SMTP clients, like @code{offlineimap}, @code{msmtp}, @code{fdm},
+@code{isync}, @code{neomutt} or @code{mutt} can use OAuth2 access tokens but
+lack the ability to renew and/or authorize OAuth2 credentials.  The purpose of
+@code{mailctl} is to provide these missing capabilities by acting as a kind of
+smart password manager.  In particular, access token renewal happens
+automatically in the background transparent to the user.
+
+If an IMAP/SMTP client cannot use an OAuth2 access token itself it may be
+\"wrapped\" with @code{fdm} and @code{msmtp} with the help of @code{mailctl}.
+
+@code{mailctl} also has some functionalities to manage the orchestration of a
+mailing system comprised of @code{msmtp}, @code{fdm}, and @code{mutt} or
+similar ones.")
+   (license license:bsd-3)))
+
 (define-public emacs-mew
   (let ((commit "35772ee0b44dd7e56b0f3899b27fa545b2bc6f03")
         (revision "1"))
-- 
2.41.0





Information forwarded to lars <at> 6xq.net, guix-patches <at> gnu.org:
bug#65976; Package guix-patches. (Mon, 25 Sep 2023 20:23:01 GMT) Full text and rfc822 format available.

Message #14 received at 65976 <at> debbugs.gnu.org (full text, mbox):

From: pinoaffe <pinoaffe <at> gmail.com>
To: 65976 <at> debbugs.gnu.org
Cc: pinoaffe <pinoaffe <at> gmail.com>
Subject: [PATCH v3 2/4] gnu: Add ghc-twain.
Date: Mon, 25 Sep 2023 22:21:32 +0200
* gnu/packages/haskell-xyz.scm (ghc-twain): New variable.
---
 gnu/packages/haskell-web.scm | 30 ++++++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)

diff --git a/gnu/packages/haskell-web.scm b/gnu/packages/haskell-web.scm
index 75b84b10a7..95f2669586 100644
--- a/gnu/packages/haskell-web.scm
+++ b/gnu/packages/haskell-web.scm
@@ -13,6 +13,7 @@
 ;;; Copyright © 2020 Alexandru-Sergiu Marton <brown121407 <at> member.fsf.org>
 ;;; Copyright © 2020 Giacomo Leidi <goodoldpaul <at> autistici.org>
 ;;; Copyright © 2022 Alice Brenon <alice.brenon <at> ens-lyon.fr>
+;;; Copyright © 2023 pinoaffe <pinoaffe <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -483,6 +484,35 @@ (define-public ghc-wai
 communication between web applications and web servers.")
     (license license:bsd-3)))
 
+(define-public ghc-twain
+  (package
+    (name "ghc-twain")
+    (version "2.1.2.0")
+    (source (origin
+              (method url-fetch)
+              (uri (hackage-uri "twain" version))
+              (sha256
+               (base32
+                "1hkzp2g671dagmv1qznkf3mw3l2mslckg7h0a8x8633h6i3j6br0"))))
+    (build-system haskell-build-system)
+    (properties '((upstream-name . "twain")))
+    (inputs (list ghc-aeson
+                  ghc-case-insensitive
+                  ghc-cookie
+                  ghc-either
+                  ghc-http-types
+                  ghc-http2
+                  ghc-vault
+                  ghc-wai
+                  ghc-wai-extra))
+    (native-inputs (list ghc-hspec ghc-hspec-discover ghc-hspec-wai))
+    (home-page "https://github.com/alexmingoia/twain#readme")
+    (synopsis "Tiny web application framework for WAI")
+    (description
+     "Twain is tiny web application framework for WAI.  It provides routing,
+parameter parsing, and an either-like monad for composing responses.")
+    (license license:bsd-3)))
+
 (define-public ghc-wai-logger
   (package
     (name "ghc-wai-logger")
-- 
2.41.0





Information forwarded to lars <at> 6xq.net, guix-patches <at> gnu.org:
bug#65976; Package guix-patches. (Mon, 25 Sep 2023 20:23:02 GMT) Full text and rfc822 format available.

Message #17 received at 65976 <at> debbugs.gnu.org (full text, mbox):

From: pinoaffe <pinoaffe <at> gmail.com>
To: 65976 <at> debbugs.gnu.org
Cc: pinoaffe <pinoaffe <at> gmail.com>
Subject: [PATCH v3 1/4] gnu: Add ghc-hsyslog.
Date: Mon, 25 Sep 2023 22:21:31 +0200
* gnu/packages/haskell-xyz.scm (ghc-hsyslog): New variable.
---
 gnu/packages/haskell-xyz.scm | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/gnu/packages/haskell-xyz.scm b/gnu/packages/haskell-xyz.scm
index c02fd007f9..6d540aee54 100644
--- a/gnu/packages/haskell-xyz.scm
+++ b/gnu/packages/haskell-xyz.scm
@@ -33,6 +33,7 @@
 ;;; Copyright © 2022 jgart <jgart <at> dismail.de>
 ;;; Copyright © 2023 Josselin Poiret <dev <at> jpoiret.xyz>
 ;;; Copyright © 2023 zamfofex <zamfofex <at> twdb.moe>
+;;; Copyright © 2023 pinoaffe <pinoaffe <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1422,6 +1423,32 @@ (define-public ghc-case-insensitive
 the resulting type will be insensitive to cases.")
     (license license:bsd-3)))
 
+(define-public ghc-hsyslog
+  (package
+    (name "ghc-hsyslog")
+    (version "5.0.2")
+    (source (origin
+              (method url-fetch)
+              (uri (hackage-uri "hsyslog" version))
+              (sha256
+               (base32
+                "1kkypn0dd92aqv8dr112bhkr9k9r9mchnyyvy41kvhj2zg447v1y"))))
+    (build-system haskell-build-system)
+    (properties '((upstream-name . "hsyslog")))
+    (arguments
+     `(#:cabal-revision ("1"
+                         "0k1j46nk3z64zw4bqmvw5lgy16ih200m66rv4b6ygjqv7nglqq0b")))
+    (home-page "https://github.com/peti/hsyslog")
+    (synopsis "FFI interface to syslog(3) from POSIX.1-2008")
+    (description
+     "This package provides a Haskell interface to @code{syslog} as specified
+in POSIX.1-2008.  The entire public API lives in @code{System.Posix.Syslog}.
+There is a set of exposed modules available underneath that one, which contain
+various implementation details that may be useful to other developers who want
+to implement syslog-related functionality.  Users of @code{syslog}, however,
+do not need them.")
+    (license license:bsd-3)))
+
 (define-public ghc-cassava
   (package
     (name "ghc-cassava")

base-commit: cf5cb0875b06b5823e9de8bbd01ddd8c0b0d15a7
-- 
2.41.0





Information forwarded to lars <at> 6xq.net, guix-patches <at> gnu.org:
bug#65976; Package guix-patches. (Mon, 25 Sep 2023 20:23:02 GMT) Full text and rfc822 format available.

Message #20 received at 65976 <at> debbugs.gnu.org (full text, mbox):

From: pinoaffe <pinoaffe <at> gmail.com>
To: 65976 <at> debbugs.gnu.org
Cc: pinoaffe <pinoaffe <at> gmail.com>
Subject: [PATCH v3 3/4] gnu: Add ghc-strings.
Date: Mon, 25 Sep 2023 22:21:33 +0200
* gnu/packages/haskell-xyz.scm (ghc-strings): New variable.
---
 gnu/packages/haskell-xyz.scm | 26 ++++++++++++++++++++++++++
 1 file changed, 26 insertions(+)

diff --git a/gnu/packages/haskell-xyz.scm b/gnu/packages/haskell-xyz.scm
index 6d540aee54..4328363a01 100644
--- a/gnu/packages/haskell-xyz.scm
+++ b/gnu/packages/haskell-xyz.scm
@@ -15961,6 +15961,32 @@ (define-public ghc-base64
 (additional support for RFC 7049 standards)")
     (license license:bsd-3)))
 
+(define-public ghc-strings
+  (package
+    (name "ghc-strings")
+    (version "1.1")
+    (source (origin
+              (method url-fetch)
+              (uri (hackage-uri "strings" version))
+              (sha256
+               (base32
+                "1xz9v3w5s13yhk7iy9dw6i8s2jc6c0b1ci96dwmcq9a1n3l3ng4v"))))
+    (build-system haskell-build-system)
+    (properties '((upstream-name . "strings")))
+    (arguments
+     `(#:cabal-revision ("1"
+                         "0jk1g71yzc5wpkr3vvhnxak61nqvisc5n90ggv6lmz4wqpqzdd0v")))
+    (home-page "https://hub.darcs.net/scravy/strings")
+    (synopsis
+     "Functions for working with strings, including Text and ByteString")
+    (description
+     "This package provides various functions for working with strings, such
+as @code{join}, @code{split}, @code{toUppercase}, et cetera.  The functions in
+this package work with all kinds of strings such as @code{Text},
+@code{ByteString}, @code{S tring}, and their respective lazy counter parts.
+There is also an interface which is agnostic of the underlying string type.")
+    (license license:expat)))
+
 (define-public ghc-ordered-containers
   (package
     (name "ghc-ordered-containers")
-- 
2.41.0





Information forwarded to guix-patches <at> gnu.org:
bug#65976; Package guix-patches. (Mon, 25 Sep 2023 20:23:02 GMT) Full text and rfc822 format available.

Message #23 received at 65976 <at> debbugs.gnu.org (full text, mbox):

From: pinoaffe <pinoaffe <at> gmail.com>
To: 65976 <at> debbugs.gnu.org
Cc: pinoaffe <pinoaffe <at> gmail.com>
Subject: [PATCH v3 4/4] gnu: Add mailctl.
Date: Mon, 25 Sep 2023 22:21:34 +0200
* gnu/packages/mail.scm (mailctl): New variable.
---
 gnu/packages/mail.scm | 58 +++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 58 insertions(+)

diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
index ecaab1c7cd..4fd3e80d90 100644
--- a/gnu/packages/mail.scm
+++ b/gnu/packages/mail.scm
@@ -52,6 +52,7 @@
 ;;; Copyright © 2022 jgart <jgart <at> dismail.de>
 ;;; Copyright © 2022 ( <paren <at> disroot.org>
 ;;; Copyright © 2023 Timo Wilken <guix <at> twilken.net>
+;;; Copyright © 2023 pinoaffe <pinoaffe <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -112,6 +113,7 @@ (define-module (gnu packages mail)
   #:use-module (gnu packages guile)
   #:use-module (gnu packages guile-xyz)
   #:use-module (gnu packages haskell-xyz)
+  #:use-module (gnu packages haskell-web)
   #:use-module (gnu packages icu4c)
   #:use-module (gnu packages kerberos)
   #:use-module (gnu packages language)
@@ -176,6 +178,7 @@ (define-module (gnu packages mail)
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system go)
   #:use-module (guix build-system guile)
+  #:use-module (guix build-system haskell)
   #:use-module (guix build-system meson)
   #:use-module (guix build-system perl)
   #:use-module (guix build-system pyproject)
@@ -1145,6 +1148,61 @@ (define-public offlineimap3
 (define-public offlineimap
   (deprecated-package "offlineimap" offlineimap3))
 
+(define-public mailctl
+  (package
+   (name "mailctl")
+   (version "0.9.1")
+   (source (origin
+            (method git-fetch)
+            (uri (git-reference
+                  (url "https://github.com/pdobsan/mailctl")
+                  (commit version)))
+            (file-name (git-file-name name version))
+            (sha256
+             (base32
+              "18mjlvf8h0afirlr2pw30p9cpcyhfw4g41c0liqbsan684cj3dk1"))))
+   (build-system haskell-build-system)
+   (home-page "https://github.com/pdobsan/mailctl")
+   (arguments `(#:phases (modify-phases %standard-phases
+                           ;; The mailctl.cabal file specifies a minimum cabal
+                           ;; version of 3.8 (which is newer than the cabal
+                           ;; packaged in guix), but doesn't use any new
+                           ;; features and it builds with 3.6.
+                           (add-after 'unpack 'patch-cabal-version
+                             (lambda _
+                               (substitute* "mailctl.cabal"
+                                 (("3.8") "3.6")))))))
+   (inputs (list ghc-aeson
+                 ghc-hsyslog
+                 ghc-http-conduit
+                 ghc-network-uri
+                 ghc-optparse-applicative
+                 ghc-pretty-simple
+                 ghc-twain
+                 ghc-base64
+                 ghc-strings
+                 ghc-utf8-string
+                 ghc-warp
+                 ghc-yaml))
+   (synopsis "Authorize and renew OAuth2 credentials for IMAP/SMTP clients")
+   (description "@code{mailctl} provides IMAP/SMTP clients with the
+capabilities of renewal and authorization of OAuth2 credentials.
+
+Many IMAP/SMTP clients, like @code{offlineimap}, @code{msmtp}, @code{fdm},
+@code{isync}, @code{neomutt} or @code{mutt} can use OAuth2 access tokens but
+lack the ability to renew and/or authorize OAuth2 credentials.  The purpose of
+@code{mailctl} is to provide these missing capabilities by acting as a kind of
+smart password manager.  In particular, access token renewal happens
+automatically in the background transparent to the user.
+
+If an IMAP/SMTP client cannot use an OAuth2 access token itself it may be
+\"wrapped\" with @code{fdm} and @code{msmtp} with the help of @code{mailctl}.
+
+@code{mailctl} also has some functionalities to manage the orchestration of a
+mailing system comprised of @code{msmtp}, @code{fdm}, and @code{mutt} or
+similar ones.")
+   (license license:bsd-3)))
+
 (define-public emacs-mew
   (let ((commit "35772ee0b44dd7e56b0f3899b27fa545b2bc6f03")
         (revision "1"))
-- 
2.41.0





Information forwarded to lars <at> 6xq.net, guix-patches <at> gnu.org:
bug#65976; Package guix-patches. (Tue, 24 Oct 2023 09:26:02 GMT) Full text and rfc822 format available.

Message #26 received at 65976 <at> debbugs.gnu.org (full text, mbox):

From: pinoaffe <pinoaffe <at> gmail.com>
To: 65976 <at> debbugs.gnu.org
Cc: pinoaffe <pinoaffe <at> gmail.com>
Subject: [PATCH v4 1/4] gnu: Add ghc-twain.
Date: Tue, 24 Oct 2023 11:24:05 +0200
* gnu/packages/haskell-xyz.scm (ghc-twain): New variable.
---
 gnu/packages/haskell-web.scm | 30 ++++++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)

diff --git a/gnu/packages/haskell-web.scm b/gnu/packages/haskell-web.scm
index 75b84b10a7..95f2669586 100644
--- a/gnu/packages/haskell-web.scm
+++ b/gnu/packages/haskell-web.scm
@@ -13,6 +13,7 @@
 ;;; Copyright © 2020 Alexandru-Sergiu Marton <brown121407 <at> member.fsf.org>
 ;;; Copyright © 2020 Giacomo Leidi <goodoldpaul <at> autistici.org>
 ;;; Copyright © 2022 Alice Brenon <alice.brenon <at> ens-lyon.fr>
+;;; Copyright © 2023 pinoaffe <pinoaffe <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -483,6 +484,35 @@ (define-public ghc-wai
 communication between web applications and web servers.")
     (license license:bsd-3)))
 
+(define-public ghc-twain
+  (package
+    (name "ghc-twain")
+    (version "2.1.2.0")
+    (source (origin
+              (method url-fetch)
+              (uri (hackage-uri "twain" version))
+              (sha256
+               (base32
+                "1hkzp2g671dagmv1qznkf3mw3l2mslckg7h0a8x8633h6i3j6br0"))))
+    (build-system haskell-build-system)
+    (properties '((upstream-name . "twain")))
+    (inputs (list ghc-aeson
+                  ghc-case-insensitive
+                  ghc-cookie
+                  ghc-either
+                  ghc-http-types
+                  ghc-http2
+                  ghc-vault
+                  ghc-wai
+                  ghc-wai-extra))
+    (native-inputs (list ghc-hspec ghc-hspec-discover ghc-hspec-wai))
+    (home-page "https://github.com/alexmingoia/twain#readme")
+    (synopsis "Tiny web application framework for WAI")
+    (description
+     "Twain is tiny web application framework for WAI.  It provides routing,
+parameter parsing, and an either-like monad for composing responses.")
+    (license license:bsd-3)))
+
 (define-public ghc-wai-logger
   (package
     (name "ghc-wai-logger")

base-commit: 7383d15641f17af5a8c656a4ad592138abc7d5ec
-- 
2.41.0





Information forwarded to lars <at> 6xq.net, guix-patches <at> gnu.org:
bug#65976; Package guix-patches. (Tue, 24 Oct 2023 09:26:02 GMT) Full text and rfc822 format available.

Message #29 received at 65976 <at> debbugs.gnu.org (full text, mbox):

From: pinoaffe <pinoaffe <at> gmail.com>
To: 65976 <at> debbugs.gnu.org
Cc: pinoaffe <pinoaffe <at> gmail.com>
Subject: [PATCH v4 2/4] gnu: Add ghc-hsyslog.
Date: Tue, 24 Oct 2023 11:24:06 +0200
* gnu/packages/haskell-xyz.scm (ghc-hsyslog): New variable.
---
 gnu/packages/haskell-xyz.scm | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/gnu/packages/haskell-xyz.scm b/gnu/packages/haskell-xyz.scm
index c02fd007f9..6d540aee54 100644
--- a/gnu/packages/haskell-xyz.scm
+++ b/gnu/packages/haskell-xyz.scm
@@ -33,6 +33,7 @@
 ;;; Copyright © 2022 jgart <jgart <at> dismail.de>
 ;;; Copyright © 2023 Josselin Poiret <dev <at> jpoiret.xyz>
 ;;; Copyright © 2023 zamfofex <zamfofex <at> twdb.moe>
+;;; Copyright © 2023 pinoaffe <pinoaffe <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1422,6 +1423,32 @@ (define-public ghc-case-insensitive
 the resulting type will be insensitive to cases.")
     (license license:bsd-3)))
 
+(define-public ghc-hsyslog
+  (package
+    (name "ghc-hsyslog")
+    (version "5.0.2")
+    (source (origin
+              (method url-fetch)
+              (uri (hackage-uri "hsyslog" version))
+              (sha256
+               (base32
+                "1kkypn0dd92aqv8dr112bhkr9k9r9mchnyyvy41kvhj2zg447v1y"))))
+    (build-system haskell-build-system)
+    (properties '((upstream-name . "hsyslog")))
+    (arguments
+     `(#:cabal-revision ("1"
+                         "0k1j46nk3z64zw4bqmvw5lgy16ih200m66rv4b6ygjqv7nglqq0b")))
+    (home-page "https://github.com/peti/hsyslog")
+    (synopsis "FFI interface to syslog(3) from POSIX.1-2008")
+    (description
+     "This package provides a Haskell interface to @code{syslog} as specified
+in POSIX.1-2008.  The entire public API lives in @code{System.Posix.Syslog}.
+There is a set of exposed modules available underneath that one, which contain
+various implementation details that may be useful to other developers who want
+to implement syslog-related functionality.  Users of @code{syslog}, however,
+do not need them.")
+    (license license:bsd-3)))
+
 (define-public ghc-cassava
   (package
     (name "ghc-cassava")
-- 
2.41.0





Information forwarded to lars <at> 6xq.net, guix-patches <at> gnu.org:
bug#65976; Package guix-patches. (Tue, 24 Oct 2023 09:26:03 GMT) Full text and rfc822 format available.

Message #32 received at 65976 <at> debbugs.gnu.org (full text, mbox):

From: pinoaffe <pinoaffe <at> gmail.com>
To: 65976 <at> debbugs.gnu.org
Cc: pinoaffe <pinoaffe <at> gmail.com>
Subject: [PATCH v4 3/4] gnu: Add ghc-strings.
Date: Tue, 24 Oct 2023 11:24:07 +0200
* gnu/packages/haskell-xyz.scm (ghc-strings): New variable.
---
 gnu/packages/haskell-xyz.scm | 26 ++++++++++++++++++++++++++
 1 file changed, 26 insertions(+)

diff --git a/gnu/packages/haskell-xyz.scm b/gnu/packages/haskell-xyz.scm
index 6d540aee54..4328363a01 100644
--- a/gnu/packages/haskell-xyz.scm
+++ b/gnu/packages/haskell-xyz.scm
@@ -15961,6 +15961,32 @@ (define-public ghc-base64
 (additional support for RFC 7049 standards)")
     (license license:bsd-3)))
 
+(define-public ghc-strings
+  (package
+    (name "ghc-strings")
+    (version "1.1")
+    (source (origin
+              (method url-fetch)
+              (uri (hackage-uri "strings" version))
+              (sha256
+               (base32
+                "1xz9v3w5s13yhk7iy9dw6i8s2jc6c0b1ci96dwmcq9a1n3l3ng4v"))))
+    (build-system haskell-build-system)
+    (properties '((upstream-name . "strings")))
+    (arguments
+     `(#:cabal-revision ("1"
+                         "0jk1g71yzc5wpkr3vvhnxak61nqvisc5n90ggv6lmz4wqpqzdd0v")))
+    (home-page "https://hub.darcs.net/scravy/strings")
+    (synopsis
+     "Functions for working with strings, including Text and ByteString")
+    (description
+     "This package provides various functions for working with strings, such
+as @code{join}, @code{split}, @code{toUppercase}, et cetera.  The functions in
+this package work with all kinds of strings such as @code{Text},
+@code{ByteString}, @code{S tring}, and their respective lazy counter parts.
+There is also an interface which is agnostic of the underlying string type.")
+    (license license:expat)))
+
 (define-public ghc-ordered-containers
   (package
     (name "ghc-ordered-containers")
-- 
2.41.0





Information forwarded to guix-patches <at> gnu.org:
bug#65976; Package guix-patches. (Tue, 24 Oct 2023 09:26:03 GMT) Full text and rfc822 format available.

Message #35 received at 65976 <at> debbugs.gnu.org (full text, mbox):

From: pinoaffe <pinoaffe <at> gmail.com>
To: 65976 <at> debbugs.gnu.org
Cc: pinoaffe <pinoaffe <at> gmail.com>
Subject: [PATCH v4 4/4] gnu: Add mailctl.
Date: Tue, 24 Oct 2023 11:24:08 +0200
* gnu/packages/mail.scm (mailctl): New variable.
---
 gnu/packages/mail.scm | 58 +++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 58 insertions(+)

diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
index 9f410047e2..78bff0546c 100644
--- a/gnu/packages/mail.scm
+++ b/gnu/packages/mail.scm
@@ -54,6 +54,7 @@
 ;;; Copyright © 2023 Timo Wilken <guix <at> twilken.net>
 ;;; Copyright © 2023 Arjan Adriaanse <arjan <at> adriaan.se>
 ;;; Copyright © 2023 Wilko Meyer <w <at> wmeyer.eu>
+;;; Copyright © 2023 pinoaffe <pinoaffe <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -115,6 +116,7 @@ (define-module (gnu packages mail)
   #:use-module (gnu packages guile)
   #:use-module (gnu packages guile-xyz)
   #:use-module (gnu packages haskell-xyz)
+  #:use-module (gnu packages haskell-web)
   #:use-module (gnu packages icu4c)
   #:use-module (gnu packages kerberos)
   #:use-module (gnu packages language)
@@ -179,6 +181,7 @@ (define-module (gnu packages mail)
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system go)
   #:use-module (guix build-system guile)
+  #:use-module (guix build-system haskell)
   #:use-module (guix build-system meson)
   #:use-module (guix build-system perl)
   #:use-module (guix build-system pyproject)
@@ -1148,6 +1151,61 @@ (define-public offlineimap3
 (define-public offlineimap
   (deprecated-package "offlineimap" offlineimap3))
 
+(define-public mailctl
+  (package
+   (name "mailctl")
+   (version "0.9.1")
+   (source (origin
+            (method git-fetch)
+            (uri (git-reference
+                  (url "https://github.com/pdobsan/mailctl")
+                  (commit version)))
+            (file-name (git-file-name name version))
+            (sha256
+             (base32
+              "18mjlvf8h0afirlr2pw30p9cpcyhfw4g41c0liqbsan684cj3dk1"))))
+   (build-system haskell-build-system)
+   (home-page "https://github.com/pdobsan/mailctl")
+   (arguments `(#:phases (modify-phases %standard-phases
+                           ;; The mailctl.cabal file specifies a minimum cabal
+                           ;; version of 3.8 (which is newer than the cabal
+                           ;; packaged in guix), but doesn't use any new
+                           ;; features and it builds with 3.6.
+                           (add-after 'unpack 'patch-cabal-version
+                             (lambda _
+                               (substitute* "mailctl.cabal"
+                                 (("3.8") "3.6")))))))
+   (inputs (list ghc-aeson
+                 ghc-hsyslog
+                 ghc-http-conduit
+                 ghc-network-uri
+                 ghc-optparse-applicative
+                 ghc-pretty-simple
+                 ghc-twain
+                 ghc-base64
+                 ghc-strings
+                 ghc-utf8-string
+                 ghc-warp
+                 ghc-yaml))
+   (synopsis "Authorize and renew OAuth2 credentials for IMAP/SMTP clients")
+   (description "@code{mailctl} provides IMAP/SMTP clients with the
+capabilities of renewal and authorization of OAuth2 credentials.
+
+Many IMAP/SMTP clients, like @code{offlineimap}, @code{msmtp}, @code{fdm},
+@code{isync}, @code{neomutt} or @code{mutt} can use OAuth2 access tokens but
+lack the ability to renew and/or authorize OAuth2 credentials.  The purpose of
+@code{mailctl} is to provide these missing capabilities by acting as a kind of
+smart password manager.  In particular, access token renewal happens
+automatically in the background transparent to the user.
+
+If an IMAP/SMTP client cannot use an OAuth2 access token itself it may be
+\"wrapped\" with @code{fdm} and @code{msmtp} with the help of @code{mailctl}.
+
+@code{mailctl} also has some functionalities to manage the orchestration of a
+mailing system comprised of @code{msmtp}, @code{fdm}, and @code{mutt} or
+similar ones.")
+   (license license:bsd-3)))
+
 (define-public emacs-mew
   (let ((commit "35772ee0b44dd7e56b0f3899b27fa545b2bc6f03")
         (revision "1"))
-- 
2.41.0





This bug report was last modified 193 days ago.

Previous Next


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