Closed danners closed 9 years ago
Hey, i run it by mistake on dir the user had no permission on. I think the could should have catched it. It crashed with the following trace:
remote: Error generating galleries: class or module required for rescue clause remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:168:in rescue in block in initialize' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:163:inblock in initialize' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:125:in foreach' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:125:ininitialize' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:218:in new' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:218:inblock in generate' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:215:in foreach' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:215:ingenerate' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/site.rb:280:in block in generate' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/site.rb:279:ineach' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/site.rb:279:in generate' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/site.rb:50:inprocess' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/command.rb:28:in process_site' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/commands/build.rb:56:inbuild' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/commands/build.rb:34:in process' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/commands/build.rb:18:inblock (2 levels) in init_with_program' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary/command.rb:220:in call' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary/command.rb:220:inblock in execute' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary/command.rb:220:in each' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary/command.rb:220:inexecute' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary/program.rb:42:in go' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary.rb:19:inprogram' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/bin/jekyll:20:in <top (required)>' remote: /usr/local/bin/jekyll:23:inload' remote: /usr/local/bin/jekyll:23:in `' remote: jekyll 2.5.3 | Error: Permission denied @ rb_sysopen - /home/simon/deployed_blog/photos/index.html
rescue in block in initialize' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:163:in
foreach' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:125:in
new' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:218:in
foreach' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:215:in
block in generate' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/site.rb:279:in
generate' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/site.rb:50:in
process_site' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/commands/build.rb:56:in
process' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/commands/build.rb:18:in
call' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary/command.rb:220:in
each' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary/command.rb:220:in
go' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary.rb:19:in
<top (required)>' remote: /usr/local/bin/jekyll:23:in
Instead of crashing, what would you rather have it do? There's no way to recover from such an error.
Hey, i run it by mistake on dir the user had no permission on. I think the could should have catched it. It crashed with the following trace:
remote: Error generating galleries: class or module required for rescue clause remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:168:in'
remote: jekyll 2.5.3 | Error: Permission denied @ rb_sysopen - /home/simon/deployed_blog/photos/index.html
rescue in block in initialize' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:163:in
block in initialize' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:125:inforeach' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:125:in
initialize' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:218:innew' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:218:in
block in generate' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:215:inforeach' remote: /home/simon/tmp/myrepo/_plugins/jekyll-gallery-generator.rb:215:in
generate' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/site.rb:280:inblock in generate' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/site.rb:279:in
each' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/site.rb:279:ingenerate' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/site.rb:50:in
process' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/command.rb:28:inprocess_site' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/commands/build.rb:56:in
build' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/commands/build.rb:34:inprocess' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/lib/jekyll/commands/build.rb:18:in
block (2 levels) in init_with_program' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary/command.rb:220:incall' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary/command.rb:220:in
block in execute' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary/command.rb:220:ineach' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary/command.rb:220:in
execute' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary/program.rb:42:ingo' remote: /var/lib/gems/2.1.0/gems/mercenary-0.3.5/lib/mercenary.rb:19:in
program' remote: /var/lib/gems/2.1.0/gems/jekyll-2.5.3/bin/jekyll:20:in<top (required)>' remote: /usr/local/bin/jekyll:23:in
load' remote: /usr/local/bin/jekyll:23:in `