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

Guard 2.0 compatibility #12

Closed
imathis opened this issue Oct 13, 2013 · 6 comments
Closed

Guard 2.0 compatibility #12

imathis opened this issue Oct 13, 2013 · 6 comments

Comments

@imathis
Copy link
Owner

imathis commented Oct 13, 2013

Guard now expects to find the Guardfile template in lib/jekyllplus/templates/Guardfile instead of lib/jekyll-plus/templates/Guardfile. Also there are other issues related to notifications.

@taiansu
Copy link

taiansu commented Oct 13, 2013

I dug a little bit and found while executing this line , The notifiers array should be

    [{:name=>:terminal_title, :options=>{:silent=>true}}]

become

    [{":name"=>":terminal_title", ":options"=>{":silent"=>true}}]

And the culprit could be that guard use YAML.dump and YAML.load to save and load the notifiers.
After hacking out this part, this plugin works quite normally all along. (Conflict with guard-coffeescript).

@imathis
Copy link
Owner Author

imathis commented Oct 13, 2013

@taiansu thank you for looking into this. I hadn't gotten as far as you have. Reading your comment, it sounds like you're saying that this isn't a problem with GJP but Guard itself. Is that correct, or is there some way I can fix my own project?

@janko
Copy link

janko commented Feb 4, 2014

Just to let you know, safe_yaml, on which Jekyll depends, is causing this problem. It modifies YAML.load to be safe, so it doesn't turn ":keys:" into :keys anymore, but rather into ":keys" (like seen above).

@imathis
Copy link
Owner Author

imathis commented Feb 4, 2014

@janko-m Thanks for the update. Do you have a suggestion for how I can fix this?

@janko
Copy link

janko commented Feb 4, 2014

I'm actually not using Guard, my brother (who is a designer, but not a Rubyist) had an issue with this, so I looked into it, and figured I could as well let you know :)

There is a way to require safe_yaml without monkey patching existing YAML, but that's not what's Jekyll's doing :P. So I don't have any ideas on top of my head.

@imathis
Copy link
Owner Author

imathis commented Feb 4, 2014

Thanks for pitching in. So it sounds like my best bet would be to try to convert these hashes to :keys before handing them off to guard.

@imathis imathis closed this as completed Dec 15, 2014
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