garyb / purescript-codec-argonaut

Bi-directional JSON codecs for argonaut
MIT License
38 stars 16 forks source link

add name argument to prismaticCodec function AND update to purs 0.14 #33

Closed srghma closed 3 years ago

garyb commented 3 years ago

I like it - I think I should have done it this way in the first place, and probably only have the named version.

I'll fix the build and merge this later on today.

srghma commented 3 years ago

:+1: agree, I have thought too that this function should replace prismaticCodec )

srghma commented 3 years ago

updated

srghma commented 3 years ago

@garyb added update to purs 0.14

sd 'Data.Generic.Rep.Show' 'Data.Show.Generic' $(fd --no-ignore --hidden --type f .purs .)
sd 'Data.Generic.Rep.Eq' 'Data.Eq.Generic' $(fd --no-ignore --hidden --type f .purs .)
sd 'Data.Generic.Rep.Ord' 'Data.Ord.Generic' $(fd --no-ignore --hidden --type f .purs .)
sd 'Data.Argonaut.Decode.Generic.Rep' 'Data.Argonaut.Decode.Generic' $(fd --no-ignore --hidden --type f .purs .)
sd 'Data.Argonaut.Encode.Generic.Rep' 'Data.Argonaut.Encode.Generic' $(fd --no-ignore --hidden --type f .purs .)
sd 'Data.Char.Unicode' 'Data.String.Unicode' $(fd --no-ignore --hidden --type f .purs .)
sd 'Data.Bifunctor.Wrap' 'Data.Functor.Wrap' $(fd --no-ignore --hidden --type f .purs .)
sd '\# Type' 'Row Type' $(fd --no-ignore --hidden --type f .purs .)
sd 'RowList\) ' 'RowList Type) ' $(fd --no-ignore --hidden --type f .purs .)
sd ', kind ([A-Z])' ', $1' $(fd --no-ignore --hidden --type f .purs .)
sd '\( kind ([A-Z])' '( $1' $(fd --no-ignore --hidden --type f .purs .)
thomashoneyman commented 3 years ago

@srghma This needs some work:

  1. You'll need to update the bower.json file so that all the dependencies move up by a major version.
  2. You'll need to update the package.json file to move pulp to ^15.0.0, purescript to ^0.14.0, and psa to ^0.8.2
  3. You also need to update the test modules -- you've only updated the source.

If you don't have time at the moment I can take care of this tomorrow. Just let me know!

thomashoneyman commented 3 years ago

I've added a migration to PureScript 0.14 here: https://github.com/garyb/purescript-codec-argonaut/pull/35

It doesn't include the prismaticCodec function, so it doesn't close this PR.

srghma commented 3 years ago

tnx everyone! sorry didnt fix in time) trying to not touch computer)

thomashoneyman commented 3 years ago

No problem! Thanks for getting it started!