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

Simplify Guard configuration by adding an :input option #2

Closed
jacquescrocker opened this issue Apr 1, 2011 · 7 comments
Closed

Simplify Guard configuration by adding an :input option #2

jacquescrocker opened this issue Apr 1, 2011 · 7 comments

Comments

@jacquescrocker
Copy link
Contributor

for guard-coffeescript-0.1.7 on ruby 1.9.2

No matter if shallow is set to true or false, all the js files end up in the output folder as if shallow was turned on.

I traced the code (via bundle open, adding breakpoints). The shallow setting is correctly set to false, however the matches[1] is always nil

I'll keep tracing and provide a fix & pull request. Hopefully we can get this extremely frustrating issue fixed for everyone very soon

@jacquescrocker
Copy link
Contributor Author

changing the watch to have parenthesis around the coffee fixed things

watch(%r{app/coffeescripts/(.+\.coffee)})

Still... this seems really arbitrary. There has to be a better way. I think an extra configuration here would be useful. Two simple settings :input => 'app/coffeescripts and :output => 'public/javascripts/compiled' would make things 100x clearer I think.

@jacquescrocker
Copy link
Contributor Author

updated the docs slightly to reflect the need to put parenthesis around the coffee path in the watch declaration. please pull

@netzpirat
Copy link
Owner

Thank you for discover and correct the subtle missinformation in the docs - I'm very sorry about that. In addition to your work I changed the Guard configuration template to also include the parenthesis and published it with the 0.1.9 release.

I like your proposal of the :input option and it won't be much work to implement the automatic creation of a watcher when the Guard will be initialized. This will definitely simplify the configuration and makes it easier to understand.

I'll happily implement it, but I won't have time until Monday. I leave this issue open and change the title to better reflect the planned changes.

@netzpirat
Copy link
Owner

Add a shortcut notation for the Guard configuration. (Closed by eeb4b2b)

@netzpirat
Copy link
Owner

I really like the short notation and can't wait to get it out with a new version. But I have no time left for testing the changes on a project, because I go out to build a brewery with friends ;-)

@jacquescrocker
Copy link
Contributor Author

cool, no prob. testing it now using git version. thanks again for this patch

@jacquescrocker
Copy link
Contributor Author

cool, working great. Had a dependency conflict (f$%ing barista wouldn't let me install coffeescript 2.2.0) but aside from that, everything works great

netzpirat added a commit that referenced this issue May 9, 2011
Add a :hide_success option (defaulted to false) for those who only want a growl notification when compilation fails
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

2 participants