Skip to content
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

Melange support #65

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open

Melange support #65

wants to merge 7 commits into from

Conversation

actionshrimp
Copy link
Collaborator

@actionshrimp actionshrimp commented Oct 4, 2023

Simpler setup after learning from migrating other bits and pieces over to use melange. Supercedes #64.

  • The decoders lib is available asdecoders for both 'native' builds, and melange builds. That way the decoders interface can be used in shared code.
  • The actual browser implementation of decoders is available as melange-decoders.

Caveats:

  • The bucklescript build still works, but Bs_json and Bs_xml modules are renamed to Js_json and Js_xml which is a breaking API change.
  • The whole repo needs (using melange 0.1) which requires dune >= 3.8.
  • As dune 3.8 isn't available on the windows opam-repository overlay currently, the windows build is broken on CI.
  • The decoders package now requires melange to be installed.

To avoid forcing all ocaml-decoders users, even those who don't care about melange, to upgrade to dune 3.8 and install melange, we could either:

  • leave this as a melange branch which can be pinned by anyone who needs melange-decoders, as they will be using dune 3.8 anyway.
  • just merge it and anyone who needs an older version of dune or melangeless setup can stay on an older version of decoders as decoders hasn't changed much for a while.

This also hopefully resolves #59 - anyone wanting to use melange-decoders can do:

opam pin decoders git+https://github.com/mattjbray/ocaml-decoders.git#melange
opam pin melange-decoders git+https://github.com/mattjbray/ocaml-decoders.git#melange

to access the melange supported version.

@actionshrimp
Copy link
Collaborator Author

This all seems to be working ok as per the (updated) description now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Install bs-decoders from opam
2 participants