Skip to content
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
3 changes: 2 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ node_js: stable
env:
- PATH=$HOME/purescript:$PATH
install:
- TAG=$(basename $(curl --location --silent --output /dev/null -w %{url_effective} https://github.com/purescript/purescript/releases/latest))
# - TAG=$(basename $(curl --location --silent --output /dev/null -w %{url_effective} https://github.com/purescript/purescript/releases/latest))
- TAG=v0.14.0-rc3
- curl --location --output $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
Expand Down
22 changes: 11 additions & 11 deletions bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,18 @@
"package.json"
],
"dependencies": {
"purescript-bifunctors": "^4.0.0",
"purescript-control": "^4.0.0",
"purescript-either": "^4.0.0",
"purescript-foldable-traversable": "^4.0.0",
"purescript-prelude": "^4.0.0",
"purescript-newtype": "^3.0.0"
"purescript-bifunctors": "master",
"purescript-control": "master",
"purescript-either": "master",
"purescript-foldable-traversable": "master",
"purescript-prelude": "master",
"purescript-newtype": "master"
},
"devDependencies": {
"purescript-psci-support": "^4.0.0",
"purescript-console": "^4.2.0",
"purescript-generics-rep": "^6.1.0",
"purescript-ordered-collections": "^1.6.0",
"purescript-strings": "^4.0.0"
"purescript-psci-support": "master",
"purescript-console": "master",
"purescript-generics-rep": "master",
"purescript-ordered-collections": "master",
"purescript-strings": "master"
}
}
6 changes: 4 additions & 2 deletions examples/Semigroup.purs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import Data.Map as Map
import Data.Newtype (class Newtype, over2)
import Data.String (length, null, toLower, toUpper)
import Data.Validation.Semigroup (V, invalid)
import Global.Unsafe (unsafeStringify)

-- | `UnvalidatedFormData` represents the raw data we might receive from a form
-- | before any validation has been performed.
Expand Down Expand Up @@ -46,6 +45,9 @@ type ValidatedFormData =
, password :: Password
}

toString :: ValidatedFormData -> String
toString { username: (Username u)} = "{ username: '" <> u <> "', password: <not shown> }"

-- | `ValidationError` represents the potential errors we might encounter during
-- | the validation process.
data ValidationError
Expand Down Expand Up @@ -251,4 +253,4 @@ main = do
-- > pure ("{\"username\":\"alice\",\"password\":\"FooBarBaz\"}")

where
printValidation = logShow <<< (map unsafeStringify)
printValidation = logShow <<< (map toString)
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
},
"devDependencies": {
"pulp": "^15.0.0",
"purescript-psa": "^0.6.0",
"purescript-psa": "^0.8.0",
"rimraf": "^2.6.2"
}
}