nixfromnpm (empty) → 0.1.0.0
raw patch · 4 files changed
+89/−0 lines, 4 filesdep +MissingHdep +aesondep +basesetup-changed
Dependencies added: MissingH, aeson, base, bytestring, classy-prelude, data-default, directory, error-list, filepath, github, hspec, hspec-expectations, http-client-streams, io-streams, mtl, network-uri, parsec, shelly, simple-nix, system-filepath, text, text-render, unordered-containers
Files
- Setup.hs +2/−0
- nixfromnpm.cabal +70/−0
- src/Main.hs +16/−0
- test/Spec.hs +1/−0
+ Setup.hs view
@@ -0,0 +1,2 @@+import Distribution.Simple+main = defaultMain
+ nixfromnpm.cabal view
@@ -0,0 +1,70 @@+-- Initial nixfromnpm.cabal generated by cabal init. For further+-- documentation, see http://haskell.org/cabal/users-guide/++name: nixfromnpm+version: 0.1.0.0+synopsis: Generate nix expressions from npm packages.+-- description:+license: MIT+author: Allen Nelson+maintainer: anelson@narrativescience.com+-- copyright:+-- category:+build-type: Simple+-- extra-source-files:+cabal-version: >=1.10++executable nixfromnpm+ main-is: Main.hs+ -- other-modules:+ other-extensions: NoImplicitPrelude, OverloadedStrings+ build-depends: base >=4.8 && <4.9+ , classy-prelude+ , text+ , mtl+ , bytestring+ , unordered-containers+ , parsec+ , aeson+ , data-default+ , shelly+ , MissingH+ , error-list+ , text-render+ , system-filepath+ , filepath+ , network-uri+ , directory+ , simple-nix+ hs-source-dirs: src+ default-language: Haskell2010++Test-Suite spec+ Type: exitcode-stdio-1.0+ Default-Language: Haskell2010+ Hs-Source-Dirs: src+ , test+ Main-Is: Spec.hs+ Build-Depends: base >=4.8 && <4.9+ , classy-prelude+ , mtl+ , text+ , bytestring+ , unordered-containers+ , parsec+ , io-streams+ , http-client-streams+ , aeson+ , data-default+ , shelly+ , MissingH+ , github+ , hspec+ , hspec-expectations+ , error-list+ , text-render+ , system-filepath+ , filepath+ , network-uri+ , directory+ , simple-nix
+ src/Main.hs view
@@ -0,0 +1,16 @@+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE ScopedTypeVariables #-}+module Main where++----------------------------------------------------------------------------+import NixFromNpm+import Data.Text (Text)+import qualified Data.Text as T+----------------------------------------------------------------------------++main :: IO ()+main = getArgs >>= \case+ pkgName:path:_ -> dumpPkgNamed False pkgName path+ _ -> error "Incorrect number of arguments"
+ test/Spec.hs view
@@ -0,0 +1,1 @@+{-# OPTIONS_GHC -F -pgmF hspec-discover #-}