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

Add a leinify command #102

Closed
kytrinyx opened this issue Aug 29, 2014 · 6 comments
Closed

Add a leinify command #102

kytrinyx opened this issue Aug 29, 2014 · 6 comments
Milestone

Comments

@kytrinyx
Copy link
Member

See exercism/exercism#1663 and https://gist.github.com/rubysolo/d0c03cc4d5d62cfb0070 (from @rubysolo) for context and a prototype.

I'm thinking create a new handler, Leinify() in the handlers package that will read the config, get the exercism directory, and for each directory in the clojure subdirectory, leinify any not-already leinified problems.

It would bail with an error message if it can't find the exercism dir, or if it can't find a clojure directory in within it.

I haven't looked at whether or not it's straight forward to figure out if something has been leinified or not, but at first glance it seems like that should be straight-forward.

@canweriotnow
Copy link

'leinification' should primarily be as simple as generating a proper basic project.clj and moving files to the idiomatic paths (src/{{projectname}},test/{{projectname}} and handling the requires; I think the best way to do this, honestly, would be to create a lein-template for slurping in an existing project dir and using it to generate a new lein project with sensible defaults, rather than having the CLI itself try to figure out how to generate Clojure. I could work on this if it's desired to go that route.

Then exercism CLI could just invoke lein exercise {{dirname}} to reconfigure it, or people could do it manually with leiningen.

@kytrinyx
Copy link
Member Author

That sounds like a sensible approach. I'd be happy to do any of the work necessary on the CLI to tie things together.

@canweriotnow
Copy link

Cool... I can't promise when I'll have time to dive into it, but lein is pretty easy to hack, so I'll put that in the bucket with continuing to work on exercism-emacs now that xscheme is launched :)

@Tonkpils Tonkpils added this to the v2.3.0 milestone Jul 29, 2015
@kytrinyx
Copy link
Member Author

What's the status on this. Do we still want to have the leinify command?

@Tonkpils
Copy link
Contributor

My two cents on this after thinking about it for a while is that we probably should not add this to the CLI. I think it's an edge case and seems very odd to have it if a user is not using clojure.

@kytrinyx
Copy link
Member Author

Agreed. Maybe there could be an exercism-leinify clojure script or something that people could use if they wanted to.

I'm closing this.

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

No branches or pull requests

3 participants