About Me

My photo
जिंदगी की परीक्षा में कोई नम्बर नहीं मिलते है लोग आपको दिल से याद करे तो समझ लेना आप पास हो गए....

Monday 16 December 2013

ruby(1.9.2) and rails 2.3.18 setup with mysql on window 7

Environment : ruby 1.9.2 , rails 2.3.18 and windows 7 with 64 bit 

For mysql:
Step1: install mysql using mysql installer
Step 2 : http://dev.mysql.com/downloads/connector/c/
Step 3: Download mysql-connector-c-noinstall-6.0.2-win32.zip
Step 4: Decided to extract it to the root of my disk, so I ended with a folder named mysql-connector-c-noinstall-6.0.2-win32 in there.
Step 5:
gem install mysql --platform=ruby -- --with-mysql-dir=C:/mysql-connector-c-noinstall-6.0.2-win32


Step 6: Copy libmysql.dll from  connector folder which we just extracted to C:\Ruby192\bin> 




reference : http://blog.mmediasys.com/2011/07/07/installing-mysql-on-windows-7-x64-and-using-ruby-with-it/

Sunday 15 December 2013

Ruby on Rails Questions ?

1.What is the difference between bundle and bundle update?
Ans :
bundle is the same as bundle install, which does the following:
  • Check if a Gemfile.lock exists. If it does, install all gems with the exact versions specified there.
  • If the lock doesn't exist, install gems as specified in the Gemfile, using the latest available / allowable versions according to the Gemfile. Then create the Gemfile.lock to record what versions have been installed.
bundle update on the other hand, deletes / ignores your Gemfile.lock and goes straight to step two.

source : http://stackoverflow.com/questions/17174878/what-is-the-difference-between-bundle-and-bundle-update


2.