From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id UAxuElISk1/pRAAA0tVLHw (envelope-from ) for ; Fri, 23 Oct 2020 17:26:42 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id 4MFPDlISk1+6HwAAB5/wlQ (envelope-from ) for ; Fri, 23 Oct 2020 17:26:42 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id E9D079400EF for ; Fri, 23 Oct 2020 17:26:41 +0000 (UTC) Received: from localhost ([::1]:60734 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kW0ps-0004Pd-UC for larch@yhetil.org; Fri, 23 Oct 2020 13:26:40 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34116) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kW0pL-0003Vq-4R for guix-patches@gnu.org; Fri, 23 Oct 2020 13:26:07 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:46758) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kW0pK-0000QU-QU for guix-patches@gnu.org; Fri, 23 Oct 2020 13:26:06 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kW0pK-0000Fb-N9 for guix-patches@gnu.org; Fri, 23 Oct 2020 13:26:06 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#44174] [PATCH 12/16] gnu: Add ghc-cassava. Resent-From: Carlo Holl Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 23 Oct 2020 17:26:06 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44174 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 44174@debbugs.gnu.org Cc: Carlo Holl Received: via spool by 44174-submit@debbugs.gnu.org id=B44174.1603473951832 (code B ref 44174); Fri, 23 Oct 2020 17:26:06 +0000 Received: (at 44174) by debbugs.gnu.org; 23 Oct 2020 17:25:51 +0000 Received: from localhost ([127.0.0.1]:58285 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kW0p4-0000DG-17 for submit@debbugs.gnu.org; Fri, 23 Oct 2020 13:25:51 -0400 Received: from mail-pf1-f176.google.com ([209.85.210.176]:38058) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kW0WB-00086Q-Ab for 44174@debbugs.gnu.org; Fri, 23 Oct 2020 13:06:20 -0400 Received: by mail-pf1-f176.google.com with SMTP id 10so1828191pfp.5 for <44174@debbugs.gnu.org>; Fri, 23 Oct 2020 10:06:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=U0wYD/fNg5YVfEfeTRb2AWKy0w/k0SBU3jkS6AuWptk=; b=LCM9abzxdUBA5DXs1h2NKjo93vHwENjNb87dJfe+6VffzR/ncky7SRPeJSS4ojdT+1 4iIdc7xFaMXXMWvFupUCeONjXXEc80SfZAfq4hfSMN+Mk78fKRLBFCLgi+u7Zn7yL82d Nmx2wYyk5+DWVxvHR1zek/RqtFbElHRg9IYuZVFggmm6iAusgI24TKhtgfVGU8CXCvEe mKMLlBUJT4vWzi9qF5sTOx7c3IDA/NM5dpbwfBE0zzH+drz+4MDBAMficZU+BQ56Wlns lOAxGceGlKNUxXT7f2vuNaLCFJGSlvu/D1w73CfZ8/oOCYQvc3rbLmA1ZNZHiT2P90Yi AisQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=U0wYD/fNg5YVfEfeTRb2AWKy0w/k0SBU3jkS6AuWptk=; b=W0F90j81olI+ciQTBzA8OB4gLoXn/1Xoxz6qFGOcPXvXyM6EtVaNvFNOk9V29gYru6 2X7EMH093arRTagcRUnetgG3YSQgWEXT8IGDLh1WQ92hl385xppbS/eTQbyPgXcb43DE AMuQapwZiHTFSG/oyNDSCzKY+o417FAphppJAxgNoTUCsp9HRz5yLgV8fSHO/JvcgiJe CSIq4/qHB/g4QFmCK9hPl7OUZj903A40LpDiTA56tADc2VJSt0EzAtx7O2ljGvk4H/iA 34a1gZrHw7aqvyNCOZDv7mGsHTtviz+i0Kj2kKQXPsDXpRJEWJS/cnlBogZAh4vUNa4Y FjYw== X-Gm-Message-State: AOAM531ebCZOJ0u0cGtOuQeZuvtiDOYiWhWeD2PHFLLFHW/dlh18FJiN 8AU9eiGbG7cxn4KG7xFvz7t8gLLAzlI= X-Google-Smtp-Source: ABdhPJzmDN8FzQIWJkI9u8o3+0bsvjQdo1yKS9+Il7CwgEhAWkwVxs6IIdGi3R3Fzcm7/4Bug/DlXw== X-Received: by 2002:a63:e44b:: with SMTP id i11mr2926985pgk.431.1603472773202; Fri, 23 Oct 2020 10:06:13 -0700 (PDT) Received: from cehdev.hsd1.ca.comcast.net ([2603:3024:1704:300::7ae9]) by smtp.gmail.com with ESMTPSA id q10sm2976825pjd.6.2020.10.23.10.06.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 23 Oct 2020 10:06:12 -0700 (PDT) From: Carlo Holl Date: Fri, 23 Oct 2020 10:05:40 -0700 Message-Id: <20201023170544.9860-12-carloholl@gmail.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201023170544.9860-1-carloholl@gmail.com> References: <20201023170544.9860-1-carloholl@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-Mailman-Approved-At: Fri, 23 Oct 2020 13:25:42 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -1.0 (-) X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Scanner: scn0 X-Spam-Score: 6.59 Authentication-Results: aspmx1.migadu.com; dkim=fail (rsa verify failed) header.d=gmail.com header.s=20161025 header.b=LCM9abzx; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Spam: Yes X-TUID: bx1cSa2QDsGm --- gnu/packages/haskell-xyz.scm | 89 ++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) diff --git a/gnu/packages/haskell-xyz.scm b/gnu/packages/haskell-xyz.scm index bfbe601ed7..8060c2f034 100644 --- a/gnu/packages/haskell-xyz.scm +++ b/gnu/packages/haskell-xyz.scm @@ -1551,6 +1551,95 @@ constructor which can be parameterised by a string-like type like: the resulting type will be insensitive to cases.") (license license:bsd-3))) +(define-public ghc-cassava + (package + (name "ghc-cassava") + (version "0.5.2.0") + (source + (origin + (method url-fetch) + (uri (string-append + "https://hackage.haskell.org/package/cassava/cassava-" + version + ".tar.gz")) + (sha256 + (base32 + "01h1zrdqb313cjd4rqm1107azzx4czqi018c2djf66a5i7ajl3dk")))) + (build-system haskell-build-system) + (inputs + `(("ghc-attoparsec" ,ghc-attoparsec) + ("ghc-hashable" ,ghc-hashable) + ("ghc-scientific" ,ghc-scientific) + ("ghc-unordered-containers" + ,ghc-unordered-containers) + ("ghc-vector" ,ghc-vector) + ("ghc-only" ,ghc-only) + ("ghc-text-short" ,ghc-text-short) + ("ghc-bytestring-builder" + ,ghc-bytestring-builder))) + (native-inputs + `(("ghc-hunit" ,ghc-hunit) + ("ghc-quickcheck" ,ghc-quickcheck) + ("ghc-quickcheck-instances" + ,ghc-quickcheck-instances) + ("ghc-test-framework" ,ghc-test-framework) + ("ghc-test-framework-hunit" + ,ghc-test-framework-hunit) + ("ghc-test-framework-quickcheck2" + ,ghc-test-framework-quickcheck2))) + (arguments + `(#:cabal-revision + ("1" + "1ph8rf91z4nf1ryrh9s4gd1kq98jlgk2manwddkpch8k0n9xvfk4") + #:configure-flags '("--flags=-bytestring--lt-0_10_4"))) + (home-page "https://github.com/haskell-hvr/cassava") + (synopsis "CSV parsing and encoding library") + (description "@code{cassava} is a library for parsing and encoding +@url{https://tools.ietf.org/html/rfc4180, RFC 4180} compliant @url{https:// +en.wikipedia.org/wiki/Comma-separated_values, comma-separated values (CSV)} +data, which is a textual line-oriented format commonly used for exchanging +tabular data. + +@code{cassava}'s API includes support for + +@itemize @bullet + +@item +Index-based record-conversion +@item +Name-based record-conversion +@item +Typeclass directed conversion of fields and records +@item +Built-in field-conversion instances for standard types +@item +Customizable record-conversion instance derivation via GHC generics +@item +Low-level @url{https://hackage.haskell.org/package/bytestring), bytestring} +builders (see @url{https://hackage.haskell.org/package/cassava-0.5.2.0/docs/ +Data-Csv-Builder.html, Data.Csv.Builder}) +@item +Incremental decoding and encoding API (see @url{https://hackage.haskell.org/ +package/cassava-0.5.2.0/docs/Data-Csv-Incremental.html, Data.Csv.Incremental}) +@item +Streaming API for constant-space decoding (see @url{https://hackage.haskell.org/ +package/cassava-0.5.2.0/docs/Data-Csv-Streaming.html, Data.Csv.Streaming}) +@end itemize + +Moreover, this library is designed to be easy to use; for instance, here's a +very simple example of encoding CSV data: + +@verbatim +>>> Data.Csv.encode [(\"John\",27),(\"Jane\",28)] +\"John,27\r\nJane,28\r\n\" +@end verbatim + +Please refer to the documentation in @url{https://hackage.haskell.org/package/ +cassava-0.5.2.0/docs/Data-Csv.html, Data.Csv} and the included @url{https:// +hackage.haskell.org/package/cassava-0.5.2.0/#readme, README} for more usage +examples.") + (license license:bsd-3))) + (define-public ghc-cborg (package (name "ghc-cborg") -- 2.28.0