Install Ruby on Rails on Windows 7

Today I met with ruby ​​textbooks and would like to study it. The problem is that I am stuck in the installation process !: (

I can’t get a clear idea of ​​how to install RoR. For example, to write php code, I installed wamp and immediately started writing php scripts. And I use Dreamweaver CS4 as an IDE.

Can anyone enlighten me:

1) RoR installation process?

2) IDE for RoR

3) What are gems? are they modules

thanks:)

+4
source share
3 answers

UPDATE: (2011-11-05)

RubyInstaller is now mature and is the preferred installation method: http://rubyinstaller.org/

SQLite can also be installed normally.

Original post: (2010-01-25)

The best way to get started is to use the installer with one click. I recommend using the old installer ( http://rubyforge.org/frs/download.php/47082/ruby186-27_rc2.exe ) instead of the new RubyInstaller, because the latter is still a bit immature. When installing rubygems support and adding ruby ​​to the PATH parameter to facilitate access to ruby ​​binaries.

After installation (it takes some time), start the console and install the rails (and the database connector, e.g. sqlite3) using the commands

gem install rails gem install sqlite3-ruby –version=1.2.3 

(version 1.2.3 for building sqlite3 will work correctly with windows)

As you might have guessed, gems are modules for rubies, and ruby ​​on rails is one of these modules.

Now you have installed both rubies and rails, start the console and enter

 rails applicationname 

to create your first rails app. Read tutorials and documentation from here.

Rails does not need an IDE for development, you can use any decent text editor, but there are rails plugins for IDEs like eclipse, and editors like vim or emacs.

+3
source

The answer to the IDE part: besides a good text editor (vim and emacs were already proposed), I found the netbeans IDE to work very well, especially on Windows.

0
source

This page works fine and installs the latest Windows releases (mid-2011) of the entire toolbox:

  • Ruby 1.9.2-p290,
  • Rails 3.1, Git 1.7.6,
  • Sqlite 3.7.3.

Ruby Eclipse support here

Configure its use in Window / Preferences / Ruby / Interpreters / Add (RailsInstaller Windows by default is C: \ RailsInstaller \ Ruby1.9.2 \ bin \ ruby.exe)

  • Create a project File / New / Project / Ruby / Ruby and

  • add file / new / empty Ruby Script.

  • type puts "Hello, Ruby" and

  • Click Run and select Ruby Script.

Read the console and enjoy.

0
source

Source: https://habr.com/ru/post/1299303/


All Articles