Skip to content

Updating to purescript 0.7.0 #4

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jul 10, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 0 additions & 52 deletions Gruntfile.js

This file was deleted.

19 changes: 6 additions & 13 deletions bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,18 +19,11 @@
"package.json"
],
"dependencies": {
"purescript-tuples": "~0.3.0",
"purescript-either": "~0.1.4",
"purescript-monoid": "~0.2.0",
"purescript-exceptions": "~0.2.2",
"purescript-control": "~0.2.2",
"purescript-maybe": "~0.2.1",
"purescript-strings": "~0.4.5",
"purescript-monad-eff": "~0.1.0",
"purescript-lists": "~0.6.0",
"purescript-profunctor": "~0.2.1",
"purescript-control": "~0.2.6",
"purescript-foldable-traversable": "~0.3.1",
"purescript-transformers": "~0.5.1"
"purescript-console": "^0.1.0",
"purescript-exceptions": "^0.3.0",
"purescript-lists": "^0.7.0",
"purescript-profunctor": "^0.3.0",
"purescript-strings": "^0.5.2",
"purescript-transformers": "^0.6.1"
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is just being picky, but can you reduce this to:

  "dependencies": {
    "purescript-console":      "^0.1.0",
    "purescript-exceptions":   "^0.3.0",
    "purescript-lists":        "^0.7.0",
    "purescript-profunctor":   "^0.3.0",
    "purescript-strings":      "^0.5.2",
    "purescript-transformers": "^0.6.1"
  }

That will pull everything in the above, and doesn't duplicate the purescript-control requirement 😉

}
12 changes: 6 additions & 6 deletions examples/src/Examples.purs
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
module Examples where
import Debug.Trace(Trace(), trace)
import Control.Monad.Eff.Console
import Control.Monad.Eff(Eff())
import Data.Maybe(Maybe(..))
import Data.Maybe.Unsafe(fromJust)
import Data.Path.Pathy

test :: forall a. (Show a, Eq a) => String -> a -> a -> Eff (trace :: Trace) Unit
test :: forall a. (Show a, Eq a) => String -> a -> a -> Eff (print :: CONSOLE) Unit
test name actual expected= do
trace $ "Test: " ++ name
if expected == actual then trace $ "Passed: " ++ (show expected) else trace $ "Failed: Expected " ++ (show expected) ++ " but found " ++ (show actual)
print $ "Test: " ++ name
if expected == actual then print $ "Passed: " ++ (show expected) else print $ "Failed: Expected " ++ (show expected) ++ " but found " ++ (show actual)

test' :: forall a b s. String -> Path a b s -> String -> Eff (trace :: Trace) Unit
test' :: forall a b s. String -> Path a b s -> String -> Eff (print :: CONSOLE) Unit
test' n p s = test n (unsafePrintPath p) s

main = do
trace "NEW TEST"
print "NEW TEST"

-- Should not compile:
-- test "(</>) - file in dir" (printPath (file "image.png" </> dir "foo")) "./image.png/foo"
Expand Down
34 changes: 34 additions & 0 deletions gulpfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
/* jshint node: true */
"use strict";

var gulp = require("gulp"),
purescript = require("gulp-purescript"),
run = require("gulp-run"),

sources = [
"src/**/*.purs",
"bower_components/purescript-*/src/**/*.purs",
"test/**/*.purs"
],

foreigns = [
"src/**/*.js",
"bower_components/purescript-*/src/**/*.js",
"test/**/*.js"
];

gulp.task("make", function() {
return purescript.psc({ src: sources, ffi: foreigns });
});

gulp.task("test", ["make"], function() {
return purescript.pscBundle({ src: "output/**/*.js", main: "Test.Main" })
.pipe(run("node"));
});

gulp.task("dotpsci", function () {
return purescript.psci({ src: sources, ffi: foreigns })
.pipe(gulp.dest("."));
});

gulp.task("default", ["test", "dotpsci"]);
8 changes: 0 additions & 8 deletions output/examples.html

This file was deleted.

Loading