I am using rails 3 on ubuntu 10. When i trying to load rails development environment using Rails Runner command i am getting this: Usage: runner [options] (''Some.ruby(code)'' or a filename) -e, --environment=name Specifies the environment for the runner to operate under (test/development/production). Default: development -h, --help Show this help message. You can also use runner as a shebang line for your scripts like this: ------------------------------------------------------------- #!/usr/bin/env /root/workspace/anurag/script/rails runner Product.all.each { |p| p.price *= 2 ; p.save! } ------------------------------------------------------------- I also tried rails console command then i get this error: usr/local/lib/ruby/1.9.1/irb/completion.rb:9:in `require'': cannot load such file -- readline (LoadError) from /usr/local/lib/ruby/1.9.1/irb/completion.rb:9:in `<top (required)>'' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ commands/console.rb:3:in `require'' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ commands/console.rb:3:in `<top (required)>'' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ commands.rb:38:in `require'' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ commands.rb:38:in `<top (required)>'' from script/rails:6:in `require'' from script/rails:6:in `<main>'' Anyone please tell how to load Development environment. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
On 6 February 2012 09:24, Anurag Sachan <anuragsachan07-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> I am using rails 3 on ubuntu 10. When i trying to load rails > development environment using Rails Runner command > > i am getting this: > > Usage: runner [options] (''Some.ruby(code)'' or a filename) > > -e, --environment=name Specifies the environment for the > runner to operate under (test/development/production). > Default: development > > -h, --help Show this help message. > > You can also use runner as a shebang line for your scripts like this: > ------------------------------------------------------------- > #!/usr/bin/env /root/workspace/anurag/script/rails runner > > Product.all.each { |p| p.price *= 2 ; p.save! } > ------------------------------------------------------------- > > I also tried rails console command then i get this error: > > usr/local/lib/ruby/1.9.1/irb/completion.rb:9:in `require'': cannot load > such file -- readline (LoadError) > from /usr/local/lib/ruby/1.9.1/irb/completion.rb:9:in `<top > (required)>'' > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ > commands/console.rb:3:in `require'' > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ > commands/console.rb:3:in `<top (required)>'' > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ > commands.rb:38:in `require'' > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ > commands.rb:38:in `<top (required)>'' > from script/rails:6:in `require'' > from script/rails:6:in `<main>'' > > Anyone please tell how to load Development environment.Are you able to create a rails application? rails new myapp If that works go to the myapp folder and you should then be able to do rails console. Have you installed ruby and rails using RVM? If not then I strongly suggest that you do this. It will make life much easier in the long run. If you google for install rails rvm ubuntu I am sure you will find instructions for doing this. Colin -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Yes i am able to create application using rails new myapp. so can u please suggest me the link that can guide me for installing ruby and rails using RVM. On Feb 6, 5:44 am, Colin Law <clan...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> wrote:> On 6 February 2012 09:24, Anurag Sachan <anuragsacha...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > > > > > > > > I am usingrails3on ubuntu 10. When i trying toloadrails > >developmentenvironment usingRailsRunner command > > > i am getting this: > > > Usage: runner [options] (''Some.ruby(code)'' or a filename) > > > -e, --environment=name Specifies the environment for the > > runner to operate under (test/development/production). > > Default:development > > > -h, --help Show this help message. > > > You can also use runner as a shebang line for your scripts like this: > > ------------------------------------------------------------- > > #!/usr/bin/env /root/workspace/anurag/script/railsrunner > > > Product.all.each { |p| p.price *= 2 ; p.save! } > > ------------------------------------------------------------- > > > I also triedrailsconsole command then i get this error: > > > usr/local/lib/ruby/1.9.1/irb/completion.rb:9:in `require'': cannotload > > such file -- readline (LoadError) > > from /usr/local/lib/ruby/1.9.1/irb/completion.rb:9:in `<top > > (required)>'' > > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ > > commands/console.rb:3:in `require'' > > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ > > commands/console.rb:3:in `<top (required)>'' > > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ > > commands.rb:38:in `require'' > > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ > > commands.rb:38:in `<top (required)>'' > > from script/rails:6:in `require'' > > from script/rails:6:in `<main>'' > > > Anyone please tell how toloadDevelopmentenvironment. > > Are you able to create arailsapplication?railsnew myapp > If that works go to the myapp folder and you should then be able to dorailsconsole. > > Have you installed ruby andrailsusing RVM? If not then I strongly > suggest that you do this. It will make life much easier in the long > run. If you google for > installrailsrvm ubuntu > I am sure you will find instructions for doing this. > > Colin-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
On 6 February 2012 11:45, Anurag Sachan <anuragsachan07-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Yes i am able to create application using rails new myapp. so can u > please suggest me the link that can guide me for installing ruby and > rails using RVM.The third link when I google for install rails rvm ubuntu is http://ryanbigg.com/2010/12/ubuntu-ruby-rvm-rails-and-you/ which looks like a good guide. Colin> > On Feb 6, 5:44 am, Colin Law <clan...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> wrote: >> On 6 February 2012 09:24, Anurag Sachan <anuragsacha...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: >> >> >> >> >> >> >> >> >> >> > I am usingrails3on ubuntu 10. When i trying toloadrails >> >developmentenvironment usingRailsRunner command >> >> > i am getting this: >> >> > Usage: runner [options] (''Some.ruby(code)'' or a filename) >> >> > -e, --environment=name Specifies the environment for the >> > runner to operate under (test/development/production). >> > Default:development >> >> > -h, --help Show this help message. >> >> > You can also use runner as a shebang line for your scripts like this: >> > ------------------------------------------------------------- >> > #!/usr/bin/env /root/workspace/anurag/script/railsrunner >> >> > Product.all.each { |p| p.price *= 2 ; p.save! } >> > ------------------------------------------------------------- >> >> > I also triedrailsconsole command then i get this error: >> >> > usr/local/lib/ruby/1.9.1/irb/completion.rb:9:in `require'': cannotload >> > such file -- readline (LoadError) >> > from /usr/local/lib/ruby/1.9.1/irb/completion.rb:9:in `<top >> > (required)>'' >> > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ >> > commands/console.rb:3:in `require'' >> > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ >> > commands/console.rb:3:in `<top (required)>'' >> > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ >> > commands.rb:38:in `require'' >> > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ >> > commands.rb:38:in `<top (required)>'' >> > from script/rails:6:in `require'' >> > from script/rails:6:in `<main>'' >> >> > Anyone please tell how toloadDevelopmentenvironment. >> >> Are you able to create arailsapplication?railsnew myapp >> If that works go to the myapp folder and you should then be able to dorailsconsole. >> >> Have you installed ruby andrailsusing RVM? If not then I strongly >> suggest that you do this. It will make life much easier in the long >> run. If you google for >> installrailsrvm ubuntu >> I am sure you will find instructions for doing this. >> >> Colin > > -- > You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. > For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en. >-- gplus.to/clanlaw -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Thank You Colin On Feb 6, 6:52 am, Colin Law <clan...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> wrote:> On 6 February 2012 11:45, Anurag Sachan <anuragsacha...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > Yes i am able to create application using rails new myapp. so can u > > please suggest me the link that can guide me for installing ruby and > > rails using RVM. > > The third link when I google for > install rails rvm ubuntu > ishttp://ryanbigg.com/2010/12/ubuntu-ruby-rvm-rails-and-you/which > looks like a good guide. > > Colin > > > > > > > > > > > > > On Feb 6, 5:44 am, Colin Law <clan...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> wrote: > >> On 6 February 2012 09:24, Anurag Sachan <anuragsacha...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > >> > I am usingrails3on ubuntu 10. When i trying toloadrails > >> >developmentenvironment usingRailsRunner command > > >> > i am getting this: > > >> > Usage: runner [options] (''Some.ruby(code)'' or a filename) > > >> > -e, --environment=name Specifies the environment for the > >> > runner to operate under (test/development/production). > >> > Default:development > > >> > -h, --help Show this help message. > > >> > You can also use runner as a shebang line for your scripts like this: > >> > ------------------------------------------------------------- > >> > #!/usr/bin/env /root/workspace/anurag/script/railsrunner > > >> > Product.all.each { |p| p.price *= 2 ; p.save! } > >> > ------------------------------------------------------------- > > >> > I also triedrailsconsole command then i get this error: > > >> > usr/local/lib/ruby/1.9.1/irb/completion.rb:9:in `require'': cannotload > >> > such file -- readline (LoadError) > >> > from /usr/local/lib/ruby/1.9.1/irb/completion.rb:9:in `<top > >> > (required)>'' > >> > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ > >> > commands/console.rb:3:in `require'' > >> > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ > >> > commands/console.rb:3:in `<top (required)>'' > >> > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ > >> > commands.rb:38:in `require'' > >> > from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.0/lib/rails/ > >> > commands.rb:38:in `<top (required)>'' > >> > from script/rails:6:in `require'' > >> > from script/rails:6:in `<main>'' > > >> > Anyone please tell how toloadDevelopmentenvironment. > > >> Are you able to create arailsapplication?railsnew myapp > >> If that works go to the myapp folder and you should then be able to dorailsconsole. > > >> Have you installed ruby andrailsusing RVM? If not then I strongly > >> suggest that you do this. It will make life much easier in the long > >> run. If you google for > >> installrailsrvm ubuntu > >> I am sure you will find instructions for doing this. > > >> Colin > > > -- > > You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. > > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > > To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > > For more options, visit this group athttp://groups.google.com/group/rubyonrails-talk?hl=en. > > -- > gplus.to/clanlaw-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.