<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Кибер-Фанк v2.0 &#187; rails</title>
	<atom:link href="http://www.shatlovsky.ru/category/rails/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.shatlovsky.ru</link>
	<description>Information must be free</description>
	<lastBuildDate>Fri, 12 Aug 2011 09:06:30 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Инструкция по установке Ruby + Gems + Rails на Ubuntu</title>
		<link>http://www.shatlovsky.ru/2008/09/19/instrukciya-po-ustanovke-ruby-gems-rails-na-ubuntu/</link>
		<comments>http://www.shatlovsky.ru/2008/09/19/instrukciya-po-ustanovke-ruby-gems-rails-na-ubuntu/#comments</comments>
		<pubDate>Fri, 19 Sep 2008 09:04:26 +0000</pubDate>
		<dc:creator>Alex Shatlovsky</dc:creator>
				<category><![CDATA[gems]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[rails]]></category>
		<category><![CDATA[ruby]]></category>
		<category><![CDATA[ubuntu]]></category>
		<category><![CDATA[unix]]></category>

		<guid isPermaLink="false">http://shatlovsky.ru/blog/2008/09/19/instrukciya-po-ustanovke-ruby-gems-rails-na-ubuntu/</guid>
		<description><![CDATA[Ставим Ruby через менеджер пакетов apt-get: ~$ sudo apt-get install ruby rdoc irb libyaml-ruby libzlib-ruby ri libopenssl-ruby ruby1.8-dev build-essential Пакеты rdoc и irb не входят в зависимости, хотя и необходимы для Gem и Rails. Ставим RubyGems из исходников. Это позволит в дальнейшем RubyGems спокойно само-обновляться: ~$ wget &#34;http://rubyforge.org/frs/download.php/38646/rubygems-x.x.x.tgz&#34; ~$ tar -xvzf rubygems-x.x.x.tgz ~$ rm rubygems-x.x.x.tgz [...]]]></description>
			<content:encoded><![CDATA[<p>Ставим Ruby через менеджер пакетов apt-get:</p>
<pre class="bash">~$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> apt-get <span style="color: #c20cb9; font-weight: bold;">install</span> ruby rdoc irb libyaml-ruby libzlib-ruby ri libopenssl-ruby ruby1<span style="color: #000000;">.8</span>-dev build-essential</pre>
<p>Пакеты rdoc и irb не входят в зависимости, хотя и необходимы для Gem и Rails.</p>
<p>Ставим <span class="warn">RubyGems из исходников</span>. Это позволит в дальнейшем RubyGems спокойно само-обновляться:</p>
<pre class="bash">~$ <span style="color: #c20cb9; font-weight: bold;">wget</span> <span style="color: #ff0000;">&quot;http://rubyforge.org/frs/download.php/38646/rubygems-x.x.x.tgz&quot;</span>
~$ <span style="color: #c20cb9; font-weight: bold;">tar</span> -xvzf rubygems-x.x.x.tgz
~$ <span style="color: #c20cb9; font-weight: bold;">rm</span> rubygems-x.x.x.tgz
~$ <span style="color: #7a0874; font-weight: bold;">cd</span> rubygems-x.x.x
~$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> ruby setup.rb
~$ <span style="color: #7a0874; font-weight: bold;">cd</span> ..
~$ <span style="color: #c20cb9; font-weight: bold;">rm</span> -r rubygems-x.x.x</pre>
<p>(НЕЛЬЗЯ запускать установку снаружи, типа <code>use sudo ruby rubygemsx.x.x/setup.rb</code>)</p>
<p>Теперь можно обновить RubyGems</p>
<pre class="bash">~$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> gem update --system</pre>
<p>Если эта команда не сработала, то, возможно, нужно создать симлинк /usr/bin/gem1.8 -&gt; /usr/bin/gem</p>
<pre class="bash">~$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">ln</span> -s /usr/bin/gem1<span style="color: #000000;">.8</span> /usr/bin/gem</pre>
<p>Ставим Rails и mongrel через RubyGems:</p>
<pre class="bash">~$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> gem <span style="color: #c20cb9; font-weight: bold;">install</span> rails mongrel</pre>
<p>Добавляем <code>/var/lib/gems/1.8/bin/</code> в пути, и все готово!</p>
<pre class="bash">~$ <span style="color: #007800;">PATH=</span><span style="color: #007800;">$<span style="color: #7a0874; font-weight: bold;">&#123;</span>PATH<span style="color: #7a0874; font-weight: bold;">&#125;</span></span>:/var/lib/gems/<span style="color: #000000;">1.8</span>/bin/
~$ <span style="color: #7a0874; font-weight: bold;">export</span> PATH</pre>
<p>[<a href="http://wiki.rubyonrails.org/rails/pages/RailsOnUbuntu">источник</a>]</p>
<p><strong>Харитон Мизгирь пишет:</strong> NB! если при установке какого-нибудь gem'а выдается ошибка<br />
"no such file to load — mkmf"<br />
это значит, что не установлен ruby1.8-dev, libsqlite3-dev<br />
или еще какой-нибудь *-dev</p>
<pre class="bash">~$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> apt-get <span style="color: #c20cb9; font-weight: bold;">install</span> ruby1<span style="color: #000000;">.8</span>-dev libsqlite3-dev</pre>
<p>и т.д.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.shatlovsky.ru/2008/09/19/instrukciya-po-ustanovke-ruby-gems-rails-na-ubuntu/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>

