ruhoh / ruhoh.rb

http://ruhoh.com
616 stars 69 forks source link

error when publishing to github #280

Open dph01 opened 10 years ago

dph01 commented 10 years ago

When I try to publish to github, I get the following error message:

in `compile': undefined method `setup' for #<Ruhoh:0x007fbc999a8f50> (NoMethodError)

I have an empty orphaned 'master' branch, and I created a simple single page site on the gh-pages branch by following Quick Start steps on http://ruhoh.com/docs/2/.

The full details are:

$ git checkout gh-pages
Switched to branch 'gh-pages'
$ bundle exec ruhoh publish github
Deploying to GitHub Pages.
(Settings based on origin remote name: https://github.com/dph01/dph01.github.io.git)
   Type: Project page.
   Source: 'master' branch.
   Compiled: 'gh-pages' branch.
   Currently in deploy branch: 'gh-pages'; switching to source branch: 'master'...
   Switched to branch 'master'
<....>/dph01.github.io/plugins/github.rb:48:in `compile': undefined method `setup' for #<Ruhoh:0x007fbc999a8f50> (NoMethodError)
from <.....>/dph01.github.io/plugins/github.rb:32:in `run'
from /Library/Ruby/Gems/2.0.0/gems/ruhoh-2.6/lib/ruhoh/client.rb:138:in `publish'
from /Library/Ruby/Gems/2.0.0/gems/ruhoh-2.6/lib/ruhoh/client.rb:45:in `initialize'
from /Library/Ruby/Gems/2.0.0/gems/ruhoh-2.6/bin/ruhoh:41:in `new'
from /Library/Ruby/Gems/2.0.0/gems/ruhoh-2.6/bin/ruhoh:41:in `<top (required)>'
from /usr/bin/ruhoh:23:in `load'
from /usr/bin/ruhoh:23:in `<main>'

Any hints on what I might be doing wrong? Does the plugin: plugins/github.rb need to be on the master branch too?

Thanks

Damian.

plusjade commented 10 years ago

I haven't updated my code for 2.6 where I removed ruhoh.setup @jaimalcohan has kindly updated the library which should work https://gist.github.com/jaimalchohan/8090954

Try that and see if it works.

dph01 commented 10 years ago

yes that worked! Thanks.

I needed to do a manual 'git push origin master'.

plusjade commented 10 years ago

@dph01 it looks like your site should be compiling as a User/Org Page rather than a Project page. I don't see why its not doing that but I will take a look this weekend. I need to add some cucumber tests to this library!

dph01 commented 10 years ago

Also, when I do a

bundle exec ruhoh publish github

its looks like it's reseting master branch to an early commit. Just looking into it a bit more at the moment ...