Skip to content

Common generate script #451

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

Merged
merged 2 commits into from
Oct 14, 2016
Merged

Common generate script #451

merged 2 commits into from
Oct 14, 2016

Conversation

bmulvihill
Copy link
Contributor

While creating a generator for acronym and noticed how each exercise had it own generate script. This leads to a lot of code duplication since each script is almost identical.

This PR would allow for a single generate script that takes an exercise name as the argument, and regenerates the exercise. If the exercise is not found and error message will display. I tested it out on all the exercises and I had to modify two generators to ensure consistent naming.

Example usage:
bin/generate raindrops

Let me know if this is something that would be helpful!

Copy link
Member

@kotp kotp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me.

How does the contributors documentation need to be changed to communicate this change, if it does, or is it a drop in replacement?

@Insti
Copy link
Contributor

Insti commented Oct 11, 2016

Nice @bmulvihill, This is something I'd been planning on doing when I found some time, but it looks like you beat me to it.

@bmulvihill
Copy link
Contributor Author

bmulvihill commented Oct 11, 2016

@kotp @Insti the contributing doc would need to change slightly. I can update it in this PR. I can also remove all the old generate scripts.

@kotp
Copy link
Member

kotp commented Oct 11, 2016

That would be awesome!

@bmulvihill
Copy link
Contributor Author

@kotp @Insti Ok this should be good to go

@pvcarrera pvcarrera mentioned this pull request Oct 13, 2016
@kotp kotp merged commit 19e1d7a into exercism:master Oct 14, 2016
@kotp
Copy link
Member

kotp commented Oct 14, 2016

Was blocking #454

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.

3 participants