From 4ea4cd99058d07538935bd55e08802395c295794 Mon Sep 17 00:00:00 2001 From: Maxwell Huang-Hobbs Date: Sun, 29 May 2016 17:34:23 -0400 Subject: [PATCH] elm-format: init at 0.3.1 Closes #15817. abbradar: remove unneeded callPackage argument and clean up spaces. --- pkgs/development/compilers/elm/default.nix | 10 ++++++ .../compilers/elm/packages/elm-format.nix | 36 +++++++++++++++++++ 2 files changed, 46 insertions(+) create mode 100644 pkgs/development/compilers/elm/packages/elm-format.nix diff --git a/pkgs/development/compilers/elm/default.nix b/pkgs/development/compilers/elm/default.nix index 360273a7eca9..08f69ba87766 100644 --- a/pkgs/development/compilers/elm/default.nix +++ b/pkgs/development/compilers/elm/default.nix @@ -63,6 +63,16 @@ let ''; }); + /* + This is not a core Elm package, and it's hosted on GitHub. + To update, run: + + cabal2nix --jailbreak --revision refs/tags/foo http://github.com/avh4/elm-format > packages/elm-format.nix + + where foo is a tag for a new version, for example "0.3.1-alpha". + */ + elm-format = self.callPackage ./packages/elm-format.nix { }; + }; in elmPkgs // { inherit elmPkgs; diff --git a/pkgs/development/compilers/elm/packages/elm-format.nix b/pkgs/development/compilers/elm/packages/elm-format.nix new file mode 100644 index 000000000000..12550e46a971 --- /dev/null +++ b/pkgs/development/compilers/elm/packages/elm-format.nix @@ -0,0 +1,36 @@ +{ mkDerivation, aeson, ansi-terminal, ansi-wl-pprint, base, binary +, bytestring, containers, directory, edit-distance, fetchgit +, filemanip, filepath, HUnit, indents, mtl, optparse-applicative +, parsec, pretty, process, QuickCheck, quickcheck-io +, regex-applicative, split, stdenv, test-framework +, test-framework-hunit, test-framework-quickcheck2, text +, union-find, wl-pprint +}: +mkDerivation { + pname = "elm-format"; + version = "0.3.1"; + src = fetchgit { + url = "http://github.com/avh4/elm-format"; + sha256 = "04kl50kzvjf4i140dlhs6f9fd2wmk6cnvyfamx2xh8vbwbnwrkj4"; + rev = "0637f3772de2297d12ea35f5b66961e1d827552c"; + }; + isLibrary = false; + isExecutable = true; + executableHaskellDepends = [ + aeson ansi-terminal ansi-wl-pprint base binary bytestring + containers directory edit-distance filemanip filepath indents mtl + optparse-applicative parsec pretty process regex-applicative split + text + ]; + testHaskellDepends = [ + aeson ansi-terminal base binary bytestring containers directory + edit-distance filemanip filepath HUnit indents mtl parsec pretty + process QuickCheck quickcheck-io regex-applicative split + test-framework test-framework-hunit test-framework-quickcheck2 text + union-find wl-pprint + ]; + jailbreak = true; + homepage = "http://elm-lang.org"; + description = "A source code formatter for Elm"; + license = stdenv.lib.licenses.bsd3; +}