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

Layer in Spacemacs #1149

Open
dannywillems opened this issue Mar 19, 2017 · 5 comments
Open

Layer in Spacemacs #1149

dannywillems opened this issue Mar 19, 2017 · 5 comments

Comments

@dannywillems
Copy link

dannywillems commented Mar 19, 2017

Would be nice if we can only add reason in the layers configuration instead of the Emacs raw configuration.

@fredyr
Copy link
Contributor

fredyr commented Mar 19, 2017

I've started on a layer, which I managed to get working with merlin and refmt as well. It's experimental but could still be useful for further experiments.

https://github.com/fredyr/reason

One point to note is that apparently a package can only be owned by one layer, which makes the reason layer dependent on ocaml, in order to use merlin.

Lastly, instead of pulling in the reason-mode locally, it's easy to change to pull it from the repo directly as shown here:
https://github.com/facebook/reason/pull/1147/files

@rubas
Copy link
Contributor

rubas commented Mar 19, 2017

We can ensure that the ocaml layer is enabled with configuration-layer/declare-layer.
http://spacemacs.org/doc/LAYERS.html#cross-dependencies

But be aware that the ocaml layer expects an opam installation. As long as you dont install an ocaml compiler with it, you are fine - otherwise the npm install of the ReasonProject will break spectacularly.

https://github.com/reasonml/ReasonProject#install

Note: Disable any ocaml global compilers you have in your PATH. If you already have an ocaml compiler installed via opam, disable the line in your ~/.bashrc that sources the opam environment. You may even want to uninstall any ocaml compilers that you installed via brew. (We are working on a fix to this problem).

@joefiorini
Copy link

I also created a layer, before I saw this issue. I have barely even tested it yet, but if anyone is on develop give it a try, might work for you.

https://gist.github.com/joefiorini/0204b4dd72a6722f57c84ed071f49929

@actionshrimp
Copy link

I've submitted a layer to spacemacs as a PR based on @fredyr's layer with a few updates which I've been using successfully for the last few months - if anyone has any other input it'd be much appreciated.

@duianto
Copy link

duianto commented Jun 25, 2019

@actionshrimp's PR is now on the Spacemacs develop branch.
Add ReasonML layer syl20bnr/spacemacs#11963

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

No branches or pull requests

7 participants