From patchwork Tue Jan 15 15:16:23 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Gabriel Hondet X-Patchwork-Id: 746 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 892DB16A77; Tue, 15 Jan 2019 15:17:14 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, T_DKIM_INVALID,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTP id B2FA116A71 for ; Tue, 15 Jan 2019 15:17:11 +0000 (GMT) Received: from localhost ([127.0.0.1]:48091 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gjQSk-0006E7-JN for patchwork@mira.cbaines.net; Tue, 15 Jan 2019 10:17:10 -0500 Received: from eggs.gnu.org ([209.51.188.92]:52957) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gjQSe-0006B7-Rm for guix-patches@gnu.org; Tue, 15 Jan 2019 10:17:06 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gjQSd-00070r-5h for guix-patches@gnu.org; Tue, 15 Jan 2019 10:17:04 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:60984) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gjQSc-00070Y-WC for guix-patches@gnu.org; Tue, 15 Jan 2019 10:17:03 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gjQSc-0005hj-K5 for guix-patches@gnu.org; Tue, 15 Jan 2019 10:17:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#33987] [PATCH] gnu: Add ghc-tldr. Resent-From: Gabriel Hondet Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 15 Jan 2019 15:17:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 33987 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Ludovic =?utf-8?q?Court=C3=A8s?= Received: via spool by 33987-submit@debbugs.gnu.org id=B33987.154756540021888 (code B ref 33987); Tue, 15 Jan 2019 15:17:02 +0000 Received: (at 33987) by debbugs.gnu.org; 15 Jan 2019 15:16:40 +0000 Received: from localhost ([127.0.0.1]:60265 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gjQSF-0005gx-2T for submit@debbugs.gnu.org; Tue, 15 Jan 2019 10:16:39 -0500 Received: from mail-wm1-f67.google.com ([209.85.128.67]:35940) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gjQSC-0005gh-Lg for 33987@debbugs.gnu.org; Tue, 15 Jan 2019 10:16:37 -0500 Received: by mail-wm1-f67.google.com with SMTP id p6so3587557wmc.1 for <33987@debbugs.gnu.org>; Tue, 15 Jan 2019 07:16:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=references:user-agent:from:to:cc:subject:in-reply-to:date :message-id:mime-version; bh=8i3Zg+kXprq+nlkvUZimFlUGYH60fsaGC0PTIa2lQic=; b=hMg2wIdEvEqUvxgaYl5uvsHPZiGeva/G0ApRHszZjc8kHcSCm4uJPzPTCw94hgegfl Q3yMm78cutMR5sxd+OU1pHodiKdA6PQSyQwV8rkYNOC8jB2OWzYrSVO8VXT0nYkzUF2+ jfXFpzK6RkBWenJ6ebPDZ1SyTcukPGxAjWqSDwF1NMLTqj5Ugv5SSHBWukf062UFLTL4 9hLC7EvSVLpacWJvWU3iQuU/h5u/eyEJl9IYWZ7BdhD/ucwxEJBfDJa/YlxaceODlsRF k7bZrDqk01ZQePWFDBW3owzDwHgDvdrYHhF78Lhf/BbZuQ7Hk2w7bEChYJeULdD7lfEy Siig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:references:user-agent:from:to:cc:subject :in-reply-to:date:message-id:mime-version; bh=8i3Zg+kXprq+nlkvUZimFlUGYH60fsaGC0PTIa2lQic=; b=XvoUaRvcfVLFShJG3NDgK8fY58DFZvLP2EnVj2SEXCDekNoOr2ljeXVDK+Jh7he43H 7RGaZ6HAJF+Ua5uN0WUfJmgJg8VnsbZsKIfWXwZB328ckPSGRU6M82SmkcjShMlDStSl 8aq0a0nlH/8nJCiO8Bdwz+Li0mIKEtw0E1aCJlc8lcFyov0d1EHj/giVGVD4nMFUhKFV vjU0Pr4bizOkuvMm1SP5vigM0O0Oo9aPhykrj8JLBs7Wfz4l4/j2zkmkkuPFVinVI/ck JP/j9c0aMG3yruAEAyMuPl3M6wcwpAlO8GxCgmLNVa/exVIhs5hlswxKuiiefOpAnG/V QcAQ== X-Gm-Message-State: AJcUukdqQCqp78vXsz26XSNSYxJ3JuWEmsWWrgzuc3YRNtwfB9KN0e9v HLJyuG8S1YmOqd6nBHlCFAsiSkmlCaI= X-Google-Smtp-Source: ALg8bN7JygrlOUfQUW3fTdDELChR/uLTg0UX/Y6lWfyp3MiVMrxgMLGsxZsw+vgb8V6BiDlz9mWlyg== X-Received: by 2002:a1c:bd86:: with SMTP id n128mr3787630wmf.22.1547565390446; Tue, 15 Jan 2019 07:16:30 -0800 (PST) Received: from glht-x240.gmail.com ([217.109.134.89]) by smtp.gmail.com with ESMTPSA id n82sm32121012wma.42.2019.01.15.07.16.28 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 15 Jan 2019 07:16:28 -0800 (PST) References: <878szz8fzn.fsf@gmail.com> <87k1j6q44t.fsf@gnu.org> User-agent: mu4e 1.0; emacs 26.1 From: Gabriel Hondet In-reply-to: <87k1j6q44t.fsf@gnu.org> Date: Tue, 15 Jan 2019 16:16:23 +0100 Message-ID: <87d0oydk8o.fsf@gmail.com> MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: 33987@debbugs.gnu.org Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches Hello, On Mon 14 Jan 2019 at 23:13 Ludovic Courtès wrote: > This fails to build for me on 64d25f0be214795050b058047133d11f1d5dcbf5: > > --8<---------------cut here---------------start------------->8--- > [1 of 1] Compiling Tldr ( src/Tldr.hs, dist/build/Tldr.o ) > > src/Tldr.hs:60:61: error: > • Couldn't match expected type ‘Text’ > with actual type ‘text-1.2.3.0:Data.Text.Internal.Text’ > NB: ‘text-1.2.3.0:Data.Text.Internal.Text’ > is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > ‘Text’ is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > • In the second argument of ‘TIO.hPutStrLn’, namely ‘txt’ > In the expression: TIO.hPutStrLn handle txt > In an equation for ‘renderNode’: > renderNode (TEXT txt) handle = TIO.hPutStrLn handle txt > | > 60 | renderNode (TEXT txt) handle = TIO.hPutStrLn handle txt > | ^^^ > > src/Tldr.hs:61:61: error: > • Couldn't match expected type ‘Text’ > with actual type ‘text-1.2.3.0:Data.Text.Internal.Text’ > NB: ‘text-1.2.3.0:Data.Text.Internal.Text’ > is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > ‘Text’ is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > • In the second argument of ‘TIO.hPutStrLn’, namely ‘txt’ > In the expression: TIO.hPutStrLn handle txt > In an equation for ‘renderNode’: > renderNode (HTML_BLOCK txt) handle = TIO.hPutStrLn handle txt > | > 61 | renderNode (HTML_BLOCK txt) handle = TIO.hPutStrLn handle txt > | ^^^ > > src/Tldr.hs:62:61: error: > • Couldn't match expected type ‘Text’ > with actual type ‘text-1.2.3.0:Data.Text.Internal.Text’ > NB: ‘text-1.2.3.0:Data.Text.Internal.Text’ > is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > ‘Text’ is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > • In the second argument of ‘TIO.hPutStrLn’, namely ‘txt’ > In the expression: TIO.hPutStrLn handle txt > In an equation for ‘renderNode’: > renderNode (CODE_BLOCK _ txt) handle = TIO.hPutStrLn handle txt > | > 62 | renderNode (CODE_BLOCK _ txt) handle = TIO.hPutStrLn handle txt > | ^^^ > > src/Tldr.hs:63:61: error: > • Couldn't match expected type ‘Text’ > with actual type ‘text-1.2.3.0:Data.Text.Internal.Text’ > NB: ‘text-1.2.3.0:Data.Text.Internal.Text’ > is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > ‘Text’ is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > • In the second argument of ‘TIO.hPutStrLn’, namely ‘txt’ > In the expression: TIO.hPutStrLn handle txt > In an equation for ‘renderNode’: > renderNode (HTML_INLINE txt) handle = TIO.hPutStrLn handle txt > | > 63 | renderNode (HTML_INLINE txt) handle = TIO.hPutStrLn handle txt > | ^^^ > > src/Tldr.hs:64:62: error: > • Couldn't match expected type ‘Text’ > with actual type ‘text-1.2.3.0:Data.Text.Internal.Text’ > NB: ‘text-1.2.3.0:Data.Text.Internal.Text’ > is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > ‘Text’ is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > • In the second argument of ‘TIO.hPutStrLn’, namely > ‘(" " <> txt)’ > In the expression: TIO.hPutStrLn handle (" " <> txt) > In an equation for ‘renderNode’: > renderNode (CODE txt) handle = TIO.hPutStrLn handle (" " <> txt) > | > 64 | renderNode (CODE txt) handle = TIO.hPutStrLn handle (" " <> txt) > | ^^^^^^^^^^^^ > > src/Tldr.hs:87:41: error: > • Couldn't match expected type ‘Text’ > with actual type ‘text-1.2.3.0:Data.Text.Internal.Text’ > NB: ‘text-1.2.3.0:Data.Text.Internal.Text’ > is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > ‘Text’ is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > • In the expression: txt > In an equation for ‘handleSubsetNodeType’: > handleSubsetNodeType (HTML_BLOCK txt) = txt > | > 87 | handleSubsetNodeType (HTML_BLOCK txt) = txt > | ^^^ > > src/Tldr.hs:88:43: error: > • Couldn't match expected type ‘Text’ > with actual type ‘text-1.2.3.0:Data.Text.Internal.Text’ > NB: ‘text-1.2.3.0:Data.Text.Internal.Text’ > is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > ‘Text’ is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > • In the expression: txt > In an equation for ‘handleSubsetNodeType’: > handleSubsetNodeType (CODE_BLOCK _ txt) = txt > | > 88 | handleSubsetNodeType (CODE_BLOCK _ txt) = txt > | ^^^ > > src/Tldr.hs:89:35: error: > • Couldn't match expected type ‘Text’ > with actual type ‘text-1.2.3.0:Data.Text.Internal.Text’ > NB: ‘text-1.2.3.0:Data.Text.Internal.Text’ > is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > ‘Text’ is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > • In the expression: txt > In an equation for ‘handleSubsetNodeType’: > handleSubsetNodeType (TEXT txt) = txt > | > 89 | handleSubsetNodeType (TEXT txt) = txt > | ^^^ > > src/Tldr.hs:90:42: error: > • Couldn't match expected type ‘Text’ > with actual type ‘text-1.2.3.0:Data.Text.Internal.Text’ > NB: ‘text-1.2.3.0:Data.Text.Internal.Text’ > is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > ‘Text’ is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > • In the expression: txt > In an equation for ‘handleSubsetNodeType’: > handleSubsetNodeType (HTML_INLINE txt) = txt > | > 90 | handleSubsetNodeType (HTML_INLINE txt) = txt > | ^^^ > > src/Tldr.hs:91:35: error: > • Couldn't match expected type ‘Text’ > with actual type ‘text-1.2.3.0:Data.Text.Internal.Text’ > NB: ‘text-1.2.3.0:Data.Text.Internal.Text’ > is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > ‘Text’ is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > • In the expression: txt > In an equation for ‘handleSubsetNodeType’: > handleSubsetNodeType (CODE txt) = txt > | > 91 | handleSubsetNodeType (CODE txt) = txt > | ^^^ > > src/Tldr.hs:114:34: error: > • Couldn't match expected type ‘text-1.2.3.0:Data.Text.Internal.Text’ > with actual type ‘Text’ > NB: ‘Text’ > is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > ‘text-1.2.3.0:Data.Text.Internal.Text’ > is defined in ‘Data.Text.Internal’ in package ‘text-1.2.3.0’ > • In the second argument of ‘commonmarkToNode’, namely ‘page’ > In the expression: commonmarkToNode [] page > In an equation for ‘node’: node = commonmarkToNode [] page > | > 114 | let node = commonmarkToNode [] page > | ^^^^ > --8<---------------cut here---------------end--------------->8--- It builds correctly for me on 38f18309e1f13b1df9add9dafcbc634f0e15004c and on 64d25f0be214795050b058047133d11f1d5dcbf5 as well, so I don't know... But interestingly, I have already seen this error, with text-1.2.3.0 (when trying to build ghc-conduit-extra for instance). On the other hand I have removed two dependencies that were specified by the ~guix import~ command but seemed useless, as it works without them (ghc-text and ghc-ansi-terminal). * gnu/packages/haskell.scm (ghc-tldr): New variable. --- gnu/packages/haskell.scm | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) Gabriel diff --git a/gnu/packages/haskell.scm b/gnu/packages/haskell.scm index 8d0e2aef6..280d0150f 100644 --- a/gnu/packages/haskell.scm +++ b/gnu/packages/haskell.scm @@ -16,6 +16,7 @@ ;;; Copyright © 2018 Tonton ;;; Copyright © 2018 Timothy Sample ;;; Copyright © 2018 Arun Isaac +;;; Copyright © 2018 Gabriel Hondet ;;; ;;; This file is part of GNU Guix. ;;; @@ -11365,4 +11366,36 @@ embedded in your Haskell code.") avoid the problem of partial intermediate files.") (license license:expat))) +(define-public ghc-tldr + (package + (name "ghc-tldr") + (version "0.4.0.1") + (source + (origin + (method url-fetch) + (uri (string-append + "https://hackage.haskell.org/package/tldr/tldr-" + version + ".tar.gz")) + (sha256 + (base32 + "0nc581y9jjzwd8l88g48c72mla7k6q1w102akl7gl5jsk9ljamd3")))) + (build-system haskell-build-system) + (inputs + `(("ghc-cmark" ,ghc-cmark) + ("ghc-optparse-applicative" ,ghc-optparse-applicative) + ("ghc-typed-process" ,ghc-typed-process) + ("ghc-semigroups" ,ghc-semigroups))) + (native-inputs + `(("ghc-tasty" ,ghc-tasty) + ("ghc-tasty-golden" ,ghc-tasty-golden))) + (home-page + "https://github.com/psibi/tldr-hs#readme") + (synopsis "Haskell tldr client") + (description "Haskell client allowing the user to update and view +@code{tldr} pages from a shell. The @code{tldr} pages are a community effort +to simplify the man pages with practical examples.") + (license license:bsd-3))) + ;;; haskell.scm ends here -- 2.20.1