lfe-deprecated / ltool

DEPRECATED LIBRARY - See:
https://github.com/lfe-rebar3/ltool
Other
0 stars 0 forks source link

rebar3 plugins #5

Open arpunk opened 9 years ago

arpunk commented 9 years ago

With the advent of the new set of plugins we should think of how are we going to wrap the rebar3 interface.

So far I've been able to use both of the rebar3 plugins @oubiwann wrote and they work very nice, I even giggled. We could also start adding the REPL and testing (with the new test runner) using the scaffolded code we can from rebar3-lfe-version.

We could use ltool as our main project tool but leaving the implementation details to rebar3. ltool could then wrap along lcfg for providing a higher level configuration entry point for interfacing with rebar.config if we want to go that road.

Also, I was not aware that most of the thinking was done already by @oubiwann (https://github.com/lfex/ltool#separating-cli-and-library-), however I think pure LFE (even as means of an escript package) is preferred to bash.

With rebar3 we can easily create an escript package of ltool with all the goodies inside which then would download rebar3 in case of not being found, deal with $HOME/.lfe/{lib/bin} installations, interface with rebar3 using lcfg as in: lfcg -> rebar.config -> rebar3

What are your thoughts?

/cc @rvirding

oubiwann commented 9 years ago

I think past me was probably 90% in agreement with you on this. Present me is 100% in agreement :-)

Future me will be sleeping soon, so I'm off for now -- but thanks so much for all the thought you've been putting into this! It's very motivating and it will be much more fun development experience :-D

arpunk commented 9 years ago

@oubiwann No problem.

I've been looking at how the rebar3 plugin for mix is structured: https://github.com/tsloughter/rebar3_hex/tree/master/src

Looks like instead of using many plugins we can have a single codebase with all of the functionality we need in a single namespace.

The problem is that the LFE compiler code is written in Erlang and all the other plugins could be written in LFE yet they are in the same src file.

Ayways, I'm very tired. I'll give it some thoughts and get on this tomorrow.

oubiwann commented 9 years ago

I think I would prefer rebar3 plugins being a "loose confederation" -- lfetool can define the "official" rebar3/LFE plugins, but adding/integrating would be as easy as adding a new plugin dep, without the need to update the codebase, etc. I tend to avoid monolithic ventures, thus my bias ;-)