Re: [Rails] rake error while db:migrate

2011-08-04 Thread Manivannan Sivaprakasam
hi rohit, Just include the following line in your config/application .rb inside the class include Rake::DSL And also include the following line at the start of the confg/application.rb require 'rake' Thanks Regards, Manivannan.S On Wed, Aug 3,

[Rails] How to keep the rails server always ON?

2011-08-04 Thread Rubyist Rohit
I have to type: rails server, each time I want it to be running in the background. How to keep it started always in the background? -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To post to this

Re: [Rails] How to keep the rails server always ON?

2011-08-04 Thread Tower He
Apache/nginx + passenger 发自我的 iPhone 在 2011-8-4,14:48,Rubyist Rohit li...@ruby-forum.com 写道: I have to type: rails server, each time I want it to be running in the background. How to keep it started always in the background? -- Posted via http://www.ruby-forum.com/. -- You received this

[Rails] Re: How to keep the rails server always ON?

2011-08-04 Thread Rubyist Rohit
Is this a command that I have to type in the command prompt? I am using Windows 7. -- Posted via http://www.ruby-forum.com/. -- 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

[Rails] Metal - How can i do to implement the same effect in Rails3?

2011-08-04 Thread Quon
--code-begin # Allow the metal piece to run in isolation require(File.dirname(__FILE__) + /../../config/environment) unless defined?(Rails) class Accelerator def self.call(env) if env[PATH_INFO] =~ /^\/accelerator/ [200, {Content-Type = text/html}, [Hello,

[Rails] Facebook/Twitter Share Button on RoR

2011-08-04 Thread Sayuj Othayoth
Hi comrades, I want to place fb and twitter share button on my page. What is the best way to integrate RoR with FB/Twitter - Sayuj Othayoth -- 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

[Rails] Re: rake error while db:migrate

2011-08-04 Thread Rubyist Rohit
Thanks Tom. It got solved with the suggestions in that link. Thanks Mani. Will do the changes. -- Posted via http://www.ruby-forum.com/. -- 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

[Rails] Re: passing size for image_tag to view via model

2011-08-04 Thread manavortex
Hi, thanks for your reply! %= image_tag medium.small_preview, :size = medium.size % Yeah, that is the solution I found, but I don't think it's pretty. Isn't there a possibility to make this better, like link_to method_returnvalue or something? If you say no, I will cry :) -- You received

Re: [Rails] Facebook/Twitter Share Button on RoR

2011-08-04 Thread Chris Kottom
These are simple HTML/JavaScript drop-ins. You don't need to involve anything in the Rails stack beyond placing the required markup in your template. https://twitter.com/about/resources/tweetbutton http://developers.facebook.com/docs/reference/plugins/like/ On Thu, Aug 4, 2011 at 10:01 AM,

[Rails] Problem in migrating a database to Heroku

2011-08-04 Thread SW Engineer
When trying to migrate a database to `Heroku`, I get the following (Provided that I'm using `gem 'sqlite3', '1.3.3'`: $ heroku rake db:migrate (in /app) rake aborted! uninitialized constant Rake::DSL /usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:2482:in `const_missing'

[Rails] GitHub - How to resolve this issue of preventing push to origin?

2011-08-04 Thread SW Engineer
When I try to push my application to 'GitHub' using 'Git', I get the following: $ git push origin master Enter passphrase for key '/c/Users/Medicine - SWEng/.ssh/id_rsa': ERROR: Repository not found. fatal: The remote end hung up unexpectedly **EDIT:** Output of running `git

Re: [Rails] GitHub - How to resolve this issue of preventing push to origin?

2011-08-04 Thread Chris Mear
On 4 August 2011 09:14, SW Engineer li...@ruby-forum.com wrote: When I try to push my application to 'GitHub' using 'Git', I get the following:    $ git push origin master    Enter passphrase for key '/c/Users/Medicine - SWEng/.ssh/id_rsa':    ERROR: Repository not found.    fatal: The

Re: [Rails] Add virtual attribute

2011-08-04 Thread Annapoorna R
hi.. i got prob with creating mailer in rails 3 i used rails g mailer UserMailer.. .. how to define method in usermailer?n cal that method..? On Mon, Aug 1, 2011 at 12:44 AM, Colin Law clan...@googlemail.com wrote: On 31 July 2011 20:00, Linus Pettersson linus.petters...@gmail.com wrote:

[Rails] Re: Routing problem

2011-08-04 Thread Piotr Panasewicz
Any ideas? -- Posted via http://www.ruby-forum.com/. -- 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@googlegroups.com. To unsubscribe from this group, send email to

Re: [Rails] Add virtual attribute

2011-08-04 Thread Colin Law
On 4 August 2011 09:28, Annapoorna R prapoorn...@gmail.com wrote: hi.. i got prob with creating mailer in rails 3 i used rails g mailer UserMailer.. .. how to define method in usermailer?n cal that method..? What has that got to do with the subject of this thread, which is Add virtual

Re: [Rails] Re: How to keep the rails server always ON?

2011-08-04 Thread Sayuj Othayoth
hey Rubyist, those are web servers. You need to configure the web server. - sayuj On Thu, Aug 4, 2011 at 12:28 PM, Rubyist Rohit li...@ruby-forum.com wrote: Is this a command that I have to type in the command prompt? I am using Windows 7. -- Posted via http://www.ruby-forum.com/. -- You

[Rails] how to create a mailer

2011-08-04 Thread Annapoorna R
hi, i got a problem in creating a mailer using rails g mailer UserMailer .. used to send a mail to the user entered e mail-id ...in the form. -- 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

Re: [Rails] how to create a mailer

2011-08-04 Thread Manivannan Sivaprakasam
Hi annapoorna, Please give me some details about your error. On Thu, Aug 4, 2011 at 2:56 PM, Annapoorna R prapoorn...@gmail.com wrote: hi, i got a problem in creating a mailer using rails g mailer UserMailer .. used to send a mail to the user entered e mail-id ...in the

[Rails] problem with mailer in rails 3

2011-08-04 Thread Annapoorna R
hi.. i got problem with mailer i m done with = rails g mailer UserMailer = in usermailer : def signup_notification(user) @activation_url = BASE_URL+activate_user_path(user.activation_code) @user = user mail(:to = user.email_id, :subject = account activate instruction) =

[Rails] Dynamic Inline CSS

2011-08-04 Thread Jordan Adams
So I'm making a user profile page for my app. However I want the user's avatar to have an inset white box-shadow. Therefore using img / isn't an option since it doesn't support inset shadows (or at least not in Chrome). So instead I'm using a div with some inline css to set the image. Here's

[Rails] How to ping twingly

2011-08-04 Thread Paul Bergstrom
I've done my own blog in Rails. How do I add a ping service like twingly? Any gem or plugin for that? I found this at http://rpc.twingly.com/ Not sure how to implement it. -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups

[Rails] Re: Dynamic Inline CSS

2011-08-04 Thread Chirag Shah
You have to store style in some variable and then need to be apply there in div style But do you have conditional border style ? Or white shadow border should be available for all avtar images ? -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed

Re: [Rails] Metal - How can i do to implement the same effect in Rails3?

2011-08-04 Thread Conrad Taylor
On Thu, Aug 4, 2011 at 12:09 AM, Quon ixi...@gmail.com wrote: --code-begin # Allow the metal piece to run in isolation require(File.dirname(__FILE__) + /../../config/environment) unless defined?(Rails) class Accelerator def self.call(env) if env[PATH_INFO]

Re: [Rails] Re: How to keep the rails server always ON?

2011-08-04 Thread Chris Kottom
Webrick is the default web server that runs when you type rails server. When you're running it in development mode, it will reload any code changes that you might happen to make on each request, but it won't be able to pick up changes to configuration files and Ruby gems that are loaded only at

[Rails] Re: Gemfile, the asset pipeline: Why have the group :assets in your Gemfile?

2011-08-04 Thread NARKOZ
You don't need this gems in production -- You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/1fH9Xmg8e1cJ. To post to this group, send email to

[Rails] Help to render partial from fieds_for with nested attributes

2011-08-04 Thread Kleber Shimabuku
I'm using nested_attributes and trying to implement the add/remove fields on-the-fly throu ajax following Ryan Bates screencast about Nested Model (#196) Doing this, it works fine: %= f.fields_for :item_parts do |parts_form| % p class=fields %= parts_form.label :part_id %

Aw: Re: [Rails] Helper methods in coffescript files

2011-08-04 Thread robertj
Hi, apart from the fact, that it might not be a good idea in terms of performance ... Is it possible? I am trying the same. Best regards Robert -- You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To view this discussion on the web visit

Re: Re: [Rails] Helper methods in coffescript files

2011-08-04 Thread Noel
you can do myfile.js.coffee.erb first it will be processed by ERB then CoffeeScript On Thu, Aug 4, 2011 at 4:59 AM, robertj rob...@robkuz.com wrote: Hi, apart from the fact, that it might not be a good idea in terms of performance ... Is it possible? I am trying the same. Best regards

Re: Re: [Rails] Helper methods in coffescript files

2011-08-04 Thread Noel
sorry, had not read the full original post On Thu, Aug 4, 2011 at 5:32 AM, Noel wwydi...@gmail.com wrote: you can do myfile.js.coffee.erb first it will be processed by ERB then CoffeeScript On Thu, Aug 4, 2011 at 4:59 AM, robertj rob...@robkuz.com wrote: Hi, apart from the fact, that it

Aw: Re: Re: [Rails] Helper methods in coffescript files

2011-08-04 Thread robertj
Hi Noel, thanks - the question is concerning helper methods. How can I use helper methods in the asset pipeline? Best regards -- You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To view this discussion on the web visit

[Rails] Re: Problem in migrating a database to Heroku

2011-08-04 Thread 7stud --
There is plenty of information about that error online. -- Posted via http://www.ruby-forum.com/. -- 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@googlegroups.com. To unsubscribe from

Re: [Rails] Re: Problem in migrating a database to Heroku

2011-08-04 Thread Peter Hickman
Google uninitialized constant Rake::DSL As an aside having a handle like SW Engineer and failing to do something that simple will open you up to lots of grief. Unless SW stands for Soapy Water in which case you should clarify things. -- You received this message because you are subscribed to

Re: [Rails] Re: Problem in migrating a database to Heroku

2011-08-04 Thread News Aanad
Put this in your Rakefile above require 'rake' require 'rake/dsl_definition Check this: http://stackoverflow.com/questions/6085610/ruby-on-rails-and-rake-problems-uninitialized-constant-rakedsl On Thu, Aug 4, 2011 at 6:13 PM, Peter Hickman peterhickman...@googlemail.com wrote: Google

[Rails] ruby-odbc unixODBC ubuntu

2011-08-04 Thread Matt Davies
Hello there I've got a fresh ubuntu box and done some magic to it to get 32 bit unixODBC to connect to a 32 bit third party driver on a 64 bit Ubuntu box. isql is working. http://webdev.blogs.glam.ac.uk/2011/08/04/32-bit-odbc-driver-with-32-bit-unixodbc-on-a-64-bit-ubuntu-os/ I now have to

Re: [Rails] Re: [root :to = home#index] not working

2011-08-04 Thread coolesting
Your mean is that you shutdown the rails server when you browser your application of rails ? 2011/8/4 Rubyist Rohit li...@ruby-forum.com I have solved the issue. When it showed Welcome Aboard, I press CTRL+C, which stopped the server. I again started it using command: rails server This time

Re: [Rails] ruby-odbc unixODBC ubuntu

2011-08-04 Thread Colin Law
On 4 August 2011 14:19, Matt Davies li...@ruby-forum.com wrote: Hello there I've got a fresh ubuntu box and done some magic to it to get 32 bit unixODBC to connect to a 32 bit third party driver on a 64 bit Ubuntu box.  isql is working.

Re: [Rails] Re: [root :to = home#index] not working

2011-08-04 Thread Colin Law
On 4 August 2011 14:21, coolesting coolest...@gmail.com wrote: Your mean is that you shutdown the rails server when you browser your application of rails ? No need to embarrass the guy/gal further, no doubt he is embarrassed already. At least he owned up to his mistake and did not just

[Rails] Re: passing size for image_tag to view via model

2011-08-04 Thread 7stud --
I don't know enough about rails to say no. But I also don't understand what you are hoping for. -- Posted via http://www.ruby-forum.com/. -- 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

[Rails] Re: ruby-odbc unixODBC ubuntu

2011-08-04 Thread Matt Davies
Colin Law wrote in post #1014948: On 4 August 2011 14:19, Matt Davies li...@ruby-forum.com wrote: http://www.ch-werner.de/rubyodbc/ruby-odbc-0.4.tar.gz straight away, an error ruby: Can't chdir to ext (fatal) maybe it's a typo in the instructions, let's try putting a space between

[Rails] Access parent app's helper methods from rails engine

2011-08-04 Thread astjohn
All, Is there a way to access a parent application's helper methods from a Rails 3.1 engine? I'm trying to create an engine which will call something like current_user on the parent application to determine if a user is signed in or not. I would like the engine to function regardless of

[Rails] Re: problem with mailer in rails 3

2011-08-04 Thread Ajit
Annapoorna here are the steps I follow for Notification stuff 1. have a user controller and model 2. create rails mailer: rails g mailer user_mailer 3. open app/mailers/user_mailer.rb and added following method def signup_nofitication(user) @user = user end it should work now. goto console,

[Rails] Re: each do js problem

2011-08-04 Thread Neil Bye
Sorry still stuck. If you look at the attached _subcomment.html.erb you will see that I have put the jQuery inside the each loop and it obviously causes problems because the jQuery is repeated. It's inside because I get an error on the comment variable otherwise. Any ideas Neil Attachments:

[Rails] how to upgrade

2011-08-04 Thread Annapoorna R
hi can u suggest how to upgrade frm rails 2.8 to 3 and ruby 1.8.7 to 1.9.2 -- 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@googlegroups.com. To unsubscribe from this group, send email

[Rails] ec2 versus engineyard, clarrifications

2011-08-04 Thread S Ahmed
Can someone clarify for me what advantage engineyard provides over running ec2 yourself? Is it that they provide chef recipes, automate backup/restore scripts for you via a web dashboard? Or is there something more to it? i.e. if I have puppet scripts to create a server, and have backup/restore

Re: [Rails] how to upgrade

2011-08-04 Thread Walter Lee Davis
On Aug 4, 2011, at 12:47 PM, Annapoorna R wrote: hi can u suggest how to upgrade frm rails 2.8 to 3 and ruby 1.8.7 to 1.9.2 I'm sure you'll hear an echo chamber here of Use rvm! http://beginrescueend.com Follow their directions to the letter, and all will be well. Walter -- You received

[Rails] upload zip file with paperclip

2011-08-04 Thread Aashish Kiran
Hi, Senario: I have to upload a Zip file which contains flash scripts using paperclip. Now I want unZip the file into a folder and save in rails app. I could able to upload a zip file. But failing to unzip to a folder in filesystem -- code sample from rails

[Rails] Namespaces and nested resources

2011-08-04 Thread Alexander Zinchuk
Hello! I'm developing online game (Heroes fighting against Clans) and i'm planning next structure of my app: i've got top-level resources Heroes (profiles of supermembers) and Clans (profiles of groups of members). So i've got both HeroesController and ClansController. What i wanna do is give

[Rails] #create tests fail when I add FriendlyId to my model

2011-08-04 Thread Walter Lee Davis
I am doing controller testing, and I can't seem to get the create method test to pass when friendly_id is added to the mix. If I comment it out of the model, the tests all pass perfectly. The moment I add it back in, the error looks like this: 1) Error:

[Rails] Re: #create tests fail when I add FriendlyId to my model

2011-08-04 Thread Kendall Gifford
On Thursday, August 4, 2011 1:35:15 PM UTC-6, Walter Lee Davis wrote: I am doing controller testing, and I can't seem to get the create method test to pass when friendly_id is added to the mix. If I comment it out of the model, the tests all pass perfectly. The moment I add it back in,

[Rails] RubyConf Uruguay, CALL FOR PROPOSALS

2011-08-04 Thread Pablo Dejuan
Call for proposals RubyConf Uruguay We are glad to invite you to present your proposal for a talk in RubyConf Uruguay. This is the second year in a row of the main Ruby and agile technologies conference in Uruguay, as the closing event of the RubySur Tour, the most important cycle of conferences

[Rails] Re: ec2 versus engineyard, clarrifications

2011-08-04 Thread Frederick Cheung
On Aug 4, 5:48 pm, S Ahmed sahmed1...@gmail.com wrote: Can someone clarify for me what advantage engineyard provides over running ec2 yourself? Is it that they provide chef recipes, automate backup/restore scripts for you via a web dashboard? Or is there something more to it? i.e. if I

[Rails] Re: Help to render partial from fieds_for with nested attributes

2011-08-04 Thread Kleber Shimabuku
A friend of mine just realize that the problem is related to the javascript add function. And now I'm trying to fix it. div%= add_child_link Add Part, f, :item %/div on my Item model I hold the accepts_nested_attributes_for :item_parts but I still getting a error undefined method `klass'

Re: [Rails] Re: #create tests fail when I add FriendlyId to my model

2011-08-04 Thread Walter Lee Davis
On Aug 4, 2011, at 4:13 PM, Kendall Gifford wrote: I'm gonna take a stab at this and say it's because you're not posting a name parameter to the create action. Therefor, the create action is trying to create a new Brand w/out a name. Since you're using the friendly_id gem and configuring

Re: [Rails] Re: Help to render partial from fieds_for with nested attributes

2011-08-04 Thread Walter Lee Davis
On Aug 4, 2011, at 4:24 PM, Kleber Shimabuku wrote: A friend of mine just realize that the problem is related to the javascript add function. And now I'm trying to fix it. div%= add_child_link Add Part, f, :item %/div Look outside of this line. Are you sure you are inside of the

Re: [Rails] Re: #create tests fail when I add FriendlyId to my model

2011-08-04 Thread Walter Lee Davis
On Aug 4, 2011, at 4:13 PM, Kendall Gifford wrote: On Thursday, August 4, 2011 1:35:15 PM UTC-6, Walter Lee Davis wrote:I am doing controller testing, and I can't seem to get the create method test to pass when friendly_id is added to the mix. If I comment it out of the model, the tests

[Rails] [OT] RubyConf Arg 2011

2011-08-04 Thread Martin Aceto
Hi everybody! As you may know, we are organizing RubyConf Argentina 2011, November 8th-9th @ Ciudad Cultural Konex, Buenos Aires. Here is a list of the confirmed speakers: Aaron Patterson, Shugo Maeda, Scott Chacon, Matt Aimonetti, Luis Lavena, Konstantin Haase, Norman Clarke y Tom

[Rails] Creating form for associated has_many model

2011-08-04 Thread 99miles
This example shows how to create a form for an associated model 'Comment', where 'Comment' belongs_to 'Post' and 'Post has_many 'Comments'. http://edgeguides.rubyonrails.org/getting_started.html#generating-a-controller How might I modify that to display all the comments in the form, and still

[Rails] Re: Rails and Service Oriented Architecture (SOA): any downsides?

2011-08-04 Thread Lille
Hey folks, I allow that I likely mangled the use of the term 'performance', but I think the question stands, because anyone consciously refactoring their Rails app to accommodate an SOA approach would surely know it: models now implemented as services would respond to HTTP requests or messaging

Re: [Rails] Re: Rails and Service Oriented Architecture (SOA): any downsides?

2011-08-04 Thread Marc Byrd
Lille, sinatra is WAAAY better than rails for building a web service API - I've built two API's in sinatra in the past week, one of them took only 1.5h (this w/ oauth, get/put/post/delete, etc.). Compare this to when I tried to build an API in The Rails Way , which at the time was ActiveResource

[Rails] Re: Creating form for associated has_many model

2011-08-04 Thread 99miles
To ask another way: Using a Polymorphic Assocation, if Photo and Article each 'has_many' Comments, the comment form should call the CommentsController, as shown here http://railscasts.com/episodes/154-polymorphic-association -- But what if I'm editing multiple comments in one form for a given

[Rails] [ANN] Rails 3.0.10.rc1 has been released!

2011-08-04 Thread Aaron Patterson
Hi everyone, Rails 3.0.10.rc1 has been released. As usual, please try out this release candidate and report any issues to the [ruby on rails core mailing list](http://groups.google.com/group/rubyonrails-core). If no issues are found, we'll release 3.0.10 on August 8th (around 5pm PDT). If you

[Rails] Re: Rails and Service Oriented Architecture (SOA): any downsides?

2011-08-04 Thread Lille
Marc, Thanks, yes I have perceived the benefit in taking more of a Rack- based approach to Ruby web service development. Question: For any of the Ruby webs services you have built, did you consume it in another of your services or in a Rails app? Lille On Aug 4, 7:34 pm, Marc Byrd

[Rails] Ruby Midwest 2011 - Speakers Announced New Group Rates

2011-08-04 Thread Luke Pillow
Hello, I wanted to let everyone know that the Ruby Midwest 2011 conference speaker lineup has been announced. I've listed the speakers and talks below, but check out the Speakers page (http://rubymidwest.com/#speakers) on the website for details. Register now for this 2 day, single-track, 22

[Rails] Re: Help to render partial from fieds_for with nested attributes

2011-08-04 Thread Kleber Shimabuku
hi Walter, thank you for replying. it's inside the form_for code block On Aug 5, 5:41 am, Walter Lee Davis wa...@wdstudio.com wrote: On Aug 4, 2011, at 4:24 PM, Kleber Shimabuku wrote: A friend of mine just realize that the problem is related to the javascript add function. And now

[Rails] Re: Metal - How can i do to implement the same effect in Rails3?

2011-08-04 Thread Quon
Thank you for your help, I think it is what i need. On Aug 4, 6:40 pm, Conrad Taylor conra...@gmail.com wrote: On Thu, Aug 4, 2011 at 12:09 AM, Quon ixi...@gmail.com wrote: --code-begin # Allow the metal piece to run in isolation require(File.dirname(__FILE__) +

Re: [Rails] how to upgrade

2011-08-04 Thread Chirag Singhal
Install rails upgrade plugin and run all the checks to see what changes you need to make to upgrade the app. https://github.com/rails/rails_upgrade Chirag http://sumeruonrails.com On Thu, Aug 4, 2011 at 10:17 PM, Annapoorna R prapoorn...@gmail.com wrote: hi can u suggest how to upgrade frm

Re: [Rails] how to upgrade

2011-08-04 Thread Surya
you may check this: https://github.com/joshfng/railsready this script setup everything for you as per your requirement!! On Fri, Aug 5, 2011 at 9:36 AM, Chirag Singhal chirag.sing...@gmail.comwrote: Install rails upgrade plugin and run all the checks to see what changes you need to make to