diff --git a/.travis.yml b/.travis.yml index 15bacc0..891a85c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,17 +1,21 @@ language: node_js dist: trusty sudo: required -node_js: 6 +node_js: stable +env: + - PATH=$HOME/purescript:$PATH install: + - TAG=$(wget -q -O - https://github.com/purescript/purescript/releases/latest --server-response --max-redirect 0 2>&1 | sed -n -e 's/.*Location:.*tag\///p') + - wget -O $HOME/purescript.tar.gz https://github.com/purescript/purescript/releases/download/$TAG/linux64.tar.gz + - tar -xvf $HOME/purescript.tar.gz -C $HOME/ + - chmod a+x $HOME/purescript - npm install -g bower - npm install + - bower install script: - - bower install --production - npm run -s build - - bower install - - npm -s test after_success: -- >- - test $TRAVIS_TAG && - echo $GITHUB_TOKEN | pulp login && - echo y | pulp publish --no-push + - >- + test $TRAVIS_TAG && + echo $GITHUB_TOKEN | pulp login && + echo y | pulp publish --no-push diff --git a/bower.json b/bower.json index e81ee7f..e57093f 100644 --- a/bower.json +++ b/bower.json @@ -14,14 +14,14 @@ "package.json" ], "dependencies": { - "purescript-maybe": "^2.0.0", - "purescript-functions": "^2.0.0" + "purescript-maybe": "^3.0.0", + "purescript-functions": "^3.0.0" }, "repository": { "type": "git", "url": "git://github.com/paf31/purescript-nullable.git" }, "devDependencies": { - "purescript-console": "^2.0.0" + "purescript-console": "^3.0.0" } } diff --git a/package.json b/package.json index 921a344..68f8999 100644 --- a/package.json +++ b/package.json @@ -8,9 +8,8 @@ "devDependencies": { "jscs": "^2.8.0", "jshint": "^2.9.1", - "pulp": "^9.0.1", + "pulp": "^10.0.4", "purescript-psa": "^0.3.9", - "purescript": "^0.10.1", "rimraf": "^2.5.0" } } diff --git a/src/Data/Nullable.purs b/src/Data/Nullable.purs index a082a13..b8ffd15 100644 --- a/src/Data/Nullable.purs +++ b/src/Data/Nullable.purs @@ -17,7 +17,7 @@ import Data.Maybe (Maybe(..), maybe) -- | -- | This type constructor may be useful when interoperating with JavaScript functions -- | which accept or return null values. -foreign import data Nullable :: * -> * +foreign import data Nullable :: Type -> Type -- | The null value. foreign import null :: forall a. Nullable a @@ -38,8 +38,8 @@ toMaybe n = runFn3 nullable n Nothing Just instance showNullable :: Show a => Show (Nullable a) where show = maybe "null" show <<< toMaybe -instance eqNullable :: (Eq a) => Eq (Nullable a) where +instance eqNullable :: Eq a => Eq (Nullable a) where eq = eq `on` toMaybe -instance ordNullable :: (Ord a) => Ord (Nullable a) where +instance ordNullable :: Ord a => Ord (Nullable a) where compare = compare `on` toMaybe