Skip to content

Commit 83b6157

Browse files
committed
Updates for 0.11
1 parent a4d4c5b commit 83b6157

File tree

5 files changed

+39
-14
lines changed

5 files changed

+39
-14
lines changed

.travis.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
language: node_js
2+
dist: trusty
3+
sudo: required
4+
node_js: stable
5+
env:
6+
- PATH=$HOME/purescript:$PATH
7+
install:
8+
- 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')
9+
- wget -O $HOME/purescript.tar.gz https://github.com/purescript/purescript/releases/download/$TAG/linux64.tar.gz
10+
- tar -xvf $HOME/purescript.tar.gz -C $HOME/
11+
- chmod a+x $HOME/purescript
12+
- npm install -g bower
13+
- npm install
14+
script:
15+
- bower install --production
16+
- npm run -s build
17+
- bower install
18+
- npm -s test
19+
after_success:
20+
- >-
21+
test $TRAVIS_TAG &&
22+
echo $GITHUB_TOKEN | pulp login &&
23+
echo y | pulp publish --no-push

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# purescript-filterable
22

3+
[![Build status](https://travis-ci.org/LiamGoodacre/purescript-filterable.svg?branch=master)](https://travis-ci.org/LiamGoodacre/purescript-filterable)
4+
35
Classes for *filterable* and *witherable* data structures.
46

57
Inspired by [witherable](https://hackage.haskell.org/package/witherable) on hackage.

bower.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,13 @@
1818
"package.json"
1919
],
2020
"dependencies": {
21-
"purescript-foldable-traversable": "^2.2.0",
22-
"purescript-identity": "^2.0.0",
23-
"purescript-arrays": "^3.2.1",
24-
"purescript-either": "^2.1.0"
21+
"purescript-foldable-traversable": "^3.0.0",
22+
"purescript-identity": "^3.0.0",
23+
"purescript-arrays": "^4.0.0",
24+
"purescript-either": "^3.0.0"
2525
},
2626
"devDependencies": {
27-
"purescript-assert": "^2.0.0",
28-
"purescript-console": "^2.0.0"
27+
"purescript-assert": "^3.0.0",
28+
"purescript-console": "^3.0.0"
2929
}
3030
}

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
"private": true,
33
"scripts": {
44
"clean": "rimraf output && rimraf .pulp-cache",
5-
"build": "pulp build",
5+
"build": "pulp build -- --censor-lib --strict",
66
"test": "pulp test",
77
"build:docs": "rimraf docs && pulp docs"
88
},
99
"devDependencies": {
10-
"pulp": "^10.0.1",
11-
"purescript-psa": "^0.4.0",
12-
"rimraf": "^2.6.0"
10+
"pulp": "^10.0.4",
11+
"purescript-psa": "^0.5.0-rc",
12+
"rimraf": "^2.6.1"
1313
}
1414
}

src/Data/Witherable.purs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,24 +64,24 @@ filterMapByWither :: forall t a b. Witherable t =>
6464
filterMapByWither p = unwrap <<< wither (Identity <<< p)
6565

6666
-- | A default implementation of `traverse` given a `Witherable`.
67-
traverseByWither :: forall t m a b. (Witherable t, Applicative m) =>
67+
traverseByWither :: forall t m a b. Witherable t => Applicative m =>
6868
(a -> m b) -> t a -> m (t b)
6969
traverseByWither f = wither (map Just <<< f)
7070

7171
-- | A default implementation of `wither` using `wilt`.
72-
witherDefault :: forall t m a b. (Witherable t, Applicative m) =>
72+
witherDefault :: forall t m a b. Witherable t => Applicative m =>
7373
(a -> m (Maybe b)) -> t a -> m (t b)
7474
witherDefault p xs = map _.right (wilt (map convert <<< p) xs) where
7575
convert Nothing = Left unit
7676
convert (Just y) = Right y
7777

7878
-- | Partition between `Left` and `Right` values - with effects in `m`.
79-
wilted :: forall t m l r. (Witherable t, Applicative m) =>
79+
wilted :: forall t m l r. Witherable t => Applicative m =>
8080
t (m (Either l r)) -> m { left :: t l, right :: t r }
8181
wilted = wilt id
8282

8383
-- | Filter out all the `Nothing` values - with effects in `m`.
84-
withered :: forall t m x. (Witherable t, Applicative m) =>
84+
withered :: forall t m x. Witherable t => Applicative m =>
8585
t (m (Maybe x)) -> m (t x)
8686
withered = wither id
8787

0 commit comments

Comments
 (0)