summaryrefslogtreecommitdiff
path: root/dev-haskell/language-haskell-extract
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
commit8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch)
tree7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /dev-haskell/language-haskell-extract
parent30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff)
gentoo resync : 14.07.2018
Diffstat (limited to 'dev-haskell/language-haskell-extract')
-rw-r--r--dev-haskell/language-haskell-extract/Manifest3
-rw-r--r--dev-haskell/language-haskell-extract/language-haskell-extract-0.2.4.ebuild23
-rw-r--r--dev-haskell/language-haskell-extract/metadata.xml47
3 files changed, 73 insertions, 0 deletions
diff --git a/dev-haskell/language-haskell-extract/Manifest b/dev-haskell/language-haskell-extract/Manifest
new file mode 100644
index 000000000000..c8dabc708c58
--- /dev/null
+++ b/dev-haskell/language-haskell-extract/Manifest
@@ -0,0 +1,3 @@
+DIST language-haskell-extract-0.2.4.tar.gz 2458 BLAKE2B 9655707a3195c82d5eda9cfbba150d3a91e103155cb522b0d9e13456e833b5530c808435d915456c230f92c438d2989512cbff956c7fd87493e481d39a53fbd8 SHA512 6408459abf9d531ccbe7d65766d38fcb93f4d3f9c77db1a706231bf6d8ad6f845fcefc4fbb03833f45c74f21f324a44760f3c89ff093c69f1f9999e64344ab4d
+EBUILD language-haskell-extract-0.2.4.ebuild 612 BLAKE2B d2b35e62458098c8933214fae4f537010c99182126ac45dc89d9222449b5f405620bf19bae537d9ca77c956b41158175520ad49a479c99d5693f9c53695dc378 SHA512 8cf8c37531c5885524ad5c363dfa5a92222515b687ab2fa2aa7f3dc6d6e4ec3feffe289acf276e03fbe8ec7d591c9f2c6e7cf0ed2f766bd9b5cb51ec032772bf
+MISC metadata.xml 1475 BLAKE2B d0c31fb5b5c0220b46125212f7a40ab7c40f82cd58ab53d5f94931c6359178bd6b0dac93e4adeb8bf96162449cd79a106f4baac8ebbe784c6c088a20db60624a SHA512 bf65c32265a35a538f13bf8d4b2b89003077bdbc3f12ead1b6a8ee35e0d8a29da77bf37af7dfc1c2a2493b4e0d830b2664c6517c609128001065910964b75411
diff --git a/dev-haskell/language-haskell-extract/language-haskell-extract-0.2.4.ebuild b/dev-haskell/language-haskell-extract/language-haskell-extract-0.2.4.ebuild
new file mode 100644
index 000000000000..254ba2620201
--- /dev/null
+++ b/dev-haskell/language-haskell-extract/language-haskell-extract-0.2.4.ebuild
@@ -0,0 +1,23 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+# ebuild generated by hackport 0.3.2.9999
+
+CABAL_FEATURES="lib profile haddock hoogle hscolour"
+inherit haskell-cabal
+
+DESCRIPTION="Module to automatically extract functions from the local code"
+HOMEPAGE="https://github.com/finnsson/template-helper"
+SRC_URI="mirror://hackage/packages/archive/${PN}/${PV}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0/${PV}"
+KEYWORDS="amd64 x86"
+IUSE=""
+
+RDEPEND="dev-haskell/regex-posix:=[profile?]
+ >=dev-lang/ghc-6.10.4:="
+DEPEND="${RDEPEND}
+ >=dev-haskell/cabal-1.6"
diff --git a/dev-haskell/language-haskell-extract/metadata.xml b/dev-haskell/language-haskell-extract/metadata.xml
new file mode 100644
index 000000000000..157ee542b0a1
--- /dev/null
+++ b/dev-haskell/language-haskell-extract/metadata.xml
@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>haskell@gentoo.org</email>
+ <name>Gentoo Haskell</name>
+ </maintainer>
+ <longdescription>
+ @language-haskell-extract@ contains some useful helper functions on top of Template Haskell.
+
+ @functionExtractor@ extracts all functions after a regexp-pattern.
+
+ &gt; foo = "test"
+ &gt; boo = "testing"
+ &gt; bar = $(functionExtractor "oo$")
+
+ will automagically extract the functions ending with @oo@ such as
+
+ &gt; bar = [("foo",foo), ("boo",boo)]
+
+ This can be useful if you wish to extract all functions beginning with test (for a test-framework)
+ or all functions beginning with wc (for a web service).
+
+ @functionExtractorMap@ works like @functionsExtractor@ but applies a function over all function-pairs.
+
+ This functions is useful if the common return type of the functions is a type class.
+
+ Example:
+
+ &gt; secondTypeclassTest =
+ &gt; do let expected = ["45", "88.8", "\"hej\""]
+ &gt; actual = $(functionExtractorMap "^tc" [|\n f -&gt; show f|] )
+ &gt; expected @=? actual
+ &gt;
+ &gt; tcInt :: Integer
+ &gt; tcInt = 45
+ &gt;
+ &gt; tcDouble :: Double
+ &gt; tcDouble = 88.8
+ &gt;
+ &gt; tcString :: String
+ &gt; tcString = "hej"
+ </longdescription>
+ <upstream>
+ <remote-id type="github">finnsson/template-helper</remote-id>
+ </upstream>
+</pkgmetadata>