Skip to content

Instantly share code, notes, and snippets.

View mwilc0x's full-sized avatar
:shipit:

Mike Wilcox mwilc0x

:shipit:
View GitHub Profile
@mwilc0x
mwilc0x / gist:780727
Created January 15, 2011 06:06
errors encountered trying to run ruby script/server with acts_as_versioned folder placed into vendor/plugins
C:\Users\Mike\railsApps\wiki>ruby script/server
=> Booting WEBrick...
C:/Ruby187/lib/ruby/site_ruby/1.8/rubygems.rb:242:in `activate': can't activate activesupport (= 3.0.0.rc2, runtime) for [], already activated activesupport-2.1
.1 for ["rails-2.1.1"] (Gem::LoadError)
from C:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:33:in `require'
from C:/Ruby187/lib/ruby/gems/1.8/gems/activesupport-2.1.1/lib/active_support/dependencies.rb:510:in `require'
from C:/Ruby187/lib/ruby/gems/1.8/gems/activesupport-2.1.1/lib/active_support/dependencies.rb:355:in `new_constants_in'
from C:/Ruby187/lib/ruby/gems/1.8/gems/activesupport-2.1.1/lib/active_support/dependencies.rb:510:in `require'
from C:/Users/Mike/railsApps/wiki/vendor/plugins/acts_as_versioned/technoweenie-acts_as_versioned-efc726d/lib/acts_as_versioned.rb:21
from C:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:29:in `gem_original_require'
C:\Users\Mike\railsApps\wiki>ruby script/server
=> Booting WEBrick...
C:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:29:in `gem_original_require': no such file to load -- active_support/concern (MissingSourceFile)
from C:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:29:in `require'
from C:/Ruby187/lib/ruby/gems/1.8/gems/activesupport-2.1.1/lib/active_support/dependencies.rb:510:in `require'
from C:/Ruby187/lib/ruby/gems/1.8/gems/activesupport-2.1.1/lib/active_support/dependencies.rb:355:in `new_constants_in'
from C:/Ruby187/lib/ruby/gems/1.8/gems/activesupport-2.1.1/lib/active_support/dependencies.rb:510:in `require'
from C:/Users/Mike/railsApps/wiki/vendor/plugins/acts_as_versioned/lib/acts_as_versioned.rb:21
from C:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:29:in `gem_original_require'
from C:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:29:in `require'
@mwilc0x
mwilc0x / gist:781054
Created January 15, 2011 17:09
Error on localhost:3000/wiki
Routing Error
No route matches "/wiki" with {:method=>:get}
#####config/routes.rb######
ActionController::Routing::Routes.draw do |map|
map.connect '', :controller => "wiki"
@mwilc0x
mwilc0x / gist:781055
Created January 15, 2011 17:09
Error on localhost:3000/wiki
Routing Error
No route matches "/wiki" with {:method=>:get}
#####config/routes.rb######
ActionController::Routing::Routes.draw do |map|
map.connect '', :controller => "wiki"
C:\Users\Mike\railsApps\wiki>ruby script/generate scaffold page wiki
C:/Ruby187/lib/ruby/gems/1.8/gems/rails-2.1.1/lib/rails_generator/lookup.rb:211:Warning: Gem::SourceIndex#search support for R
#find_name
exists app/models/
exists app/controllers/
exists app/helpers/
exists app/views/pages
exists app/views/layouts/
exists test/functional/
exists test/unit/
NoMethodError in Wiki#index
Showing layouts/wiki.rhtml where line #9 raised:
You have a nil object when you didn't expect it!
You might have expected an instance of ActiveRecord::Base.
The error occurred while evaluating nil.[]
Extracted source (around line #9):
NoMethodError in Wiki#edit
Showing wiki/edit.rhtml where line #3 raised:
undefined method `start_form_tag' for #<ActionView::Base:0x59149f8>
Extracted source (around line #3):
1: <h1>Editing page</h1>
2:
NoMethodError in WikiController#list
undefined method `paginate' for #<WikiController:0x58857a8>
RAILS_ROOT: C:/Users/Mike/railsApps/wiki
Application Trace | Framework Trace | Full Trace
app/controllers/wiki_controller.rb:16:in `list'
C:/Ruby187/lib/ruby/gems/1.8/gems/actionpack-2.1.1/lib/action_controller/base.rb:1166:in `send'
class WikiController < ApplicationController
def index
@page = Page.find_by_title( params[:title] || 'HomePage' )
if @page.nil?
redirect_to :action => 'new', :title => params[:title]
else
@page.body.gsub!(
Regexp.new( '\b((?:[A-Z]\w+){2,})' ), '<a href="/wiki/index?title=\1">\1</a>' )
render :action => 'show'
end
@mwilc0x
mwilc0x / gist:781395
Created January 16, 2011 00:05
trying to install gollum wiki app
####command line errors#####
C:\Ruby187\lib\ruby\gems\1.8\gems\gollum-1.1.1>gollum
== Sinatra/1.1.2 has taken the stage on 4567 for development with backup from WEBrick
[2011-01-15 19:02:58] INFO WEBrick 1.3.1
[2011-01-15 19:02:58] INFO ruby 1.8.7 (2010-12-23) [i386-mingw32]
[2011-01-15 19:02:58] INFO WEBrick::HTTPServer#start: pid=4396 port=4567
Grit::InvalidGitRepositoryError - C:/Ruby187/lib/ruby/gems/1.8/gems/gollum-1.1.1:
C:/Ruby187/lib/ruby/gems/1.8/gems/grit-2.4.1/lib/grit/repo.rb:51:in `initialize'