<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <title>allenwei</title>
    <link>https://ruby-china.org/allenwei</link>
    <description></description>
    <language>en-us</language>
    <item>
      <title>falcon 的 ruby patch 真的能提高 Rails 启动速度么</title>
      <description>&lt;p&gt;试着安装了带 falcon patch 的 ruby，Rails 的启动速度并没有减少，反而增加了 1s
倒是修改 GC 参数以后快了一倍&lt;/p&gt;

&lt;p&gt;如果你还没有试过，你可以参照这篇文章
&lt;a href="http://astrails.com/blog/2012/11/13/rvm-install-patched-ruby-for-faster-rails-startup" rel="nofollow" target="_blank"&gt;http://astrails.com/blog/2012/11/13/rvm-install-patched-ruby-for-faster-rails-startup&lt;/a&gt;&lt;/p&gt;</description>
      <author>allenwei</author>
      <pubDate>Thu, 15 Nov 2012 12:25:07 +0800</pubDate>
      <link>https://ruby-china.org/topics/6776</link>
      <guid>https://ruby-china.org/topics/6776</guid>
    </item>
    <item>
      <title>抛弃 guard，改用 vim+tmux</title>
      <description>&lt;p&gt;最近看了这篇文章比较有意思&lt;/p&gt;

&lt;p&gt;普遍 TDD 的时候都是用 guard，但 guard 确实很烦，每次需要运行整个文件
用 vim 和 tmux 结合，在 vim 里用快捷键就可以发送带行号的 rspec 命令例如 &lt;code&gt;rspec spec/models/store_spec.rb:6&lt;/code&gt;
再加上 spork，
TDD 那是非常快啊&lt;/p&gt;

&lt;p&gt;可能有点标题党，我觉得 guard 也是可以用一起使用，用 guard-spork 启动 spork，在 guard-rspec 里面只添加那些触发所有测试的规则&lt;/p&gt;

&lt;p&gt;&lt;a href="http://henrik.nyh.se/octopress/2012/07/tests-on-demand-using-vimux-and-turbux-with-spork-and-guard/" rel="nofollow" target="_blank"&gt;http://henrik.nyh.se/octopress/2012/07/tests-on-demand-using-vimux-and-turbux-with-spork-and-guard/&lt;/a&gt;&lt;/p&gt;</description>
      <author>allenwei</author>
      <pubDate>Sun, 22 Jul 2012 11:38:34 +0800</pubDate>
      <link>https://ruby-china.org/topics/4479</link>
      <guid>https://ruby-china.org/topics/4479</guid>
    </item>
    <item>
      <title>如何加速 Asset Pipeline precompile</title>
      <description>&lt;p&gt;用的 scss，coffeescript, 每次 compile 一次需要 10 分钟。。。
大家有没有什么好办法  &lt;/p&gt;</description>
      <author>allenwei</author>
      <pubDate>Wed, 27 Jun 2012 09:45:17 +0800</pubDate>
      <link>https://ruby-china.org/topics/4006</link>
      <guid>https://ruby-china.org/topics/4006</guid>
    </item>
    <item>
      <title>Codeschool Free Weekend</title>
      <description>&lt;p&gt;&lt;a href="http://www.codeschool.com/free-weekend" rel="nofollow" target="_blank"&gt;http://www.codeschool.com/free-weekend&lt;/a&gt;  &lt;/p&gt;</description>
      <author>allenwei</author>
      <pubDate>Wed, 16 May 2012 10:35:54 +0800</pubDate>
      <link>https://ruby-china.org/topics/3307</link>
      <guid>https://ruby-china.org/topics/3307</guid>
    </item>
    <item>
      <title>如果一个 API 有 SOAP 和 REST 两个版本，你会选择哪个</title>
      <description>&lt;p&gt;本来一直都是 REST 的 Fans，最近看了一下 Ruby SOAP 的 client，可以自动生成一些 model 和 function 还是比较方便的  &lt;/p&gt;</description>
      <author>allenwei</author>
      <pubDate>Wed, 09 May 2012 20:13:42 +0800</pubDate>
      <link>https://ruby-china.org/topics/3177</link>
      <guid>https://ruby-china.org/topics/3177</guid>
    </item>
    <item>
      <title>推荐一个 OAuth2 Server 的实现 oauth2-provider</title>
      <description>&lt;p&gt;最近把以前写的 devise + grape 的 api 里的验证重构了
用 OAuth2 Provider &lt;a href="https://github.com/songkick/oauth2-provider" rel="nofollow" target="_blank"&gt;https://github.com/songkick/oauth2-provider&lt;/a&gt; 代替
devise authentication_token 的解决方案，太不安全了  &lt;/p&gt;</description>
      <author>allenwei</author>
      <pubDate>Sun, 26 Feb 2012 00:18:22 +0800</pubDate>
      <link>https://ruby-china.org/topics/1424</link>
      <guid>https://ruby-china.org/topics/1424</guid>
    </item>
    <item>
      <title>ActiveRecord unscoped 一定要用 block 的写法?</title>
      <description>&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Article.create :title =&amp;gt; "test"
Article.unscoped #=&amp;gt;  1 record
Article.create :title =&amp;gt; "test"
Article.unscoped #=&amp;gt;  still 1 record
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;看最下面的评论 &lt;a href="http://apidock.com/rails/ActiveRecord/Base/unscoped/class" rel="nofollow" target="_blank"&gt;http://apidock.com/rails/ActiveRecord/Base/unscoped/class&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;如果不用 unscoped 的 block 写法，结果会被缓存住，巨大的陷阱啊，
大家遇到过这个问题么？&lt;/p&gt;</description>
      <author>allenwei</author>
      <pubDate>Sun, 29 Jan 2012 23:30:54 +0800</pubDate>
      <link>https://ruby-china.org/topics/973</link>
      <guid>https://ruby-china.org/topics/973</guid>
    </item>
    <item>
      <title>MacOS Lion 不能通过局域网 ip 连接访问本地 Rails server [已解决]</title>
      <description>&lt;p&gt;localhost:3000 是可以访问的
但是
192.168.1.102:3000 就不可以
也没有打开防火墙
估计问题可能和 mac 自带的 apache 有关
有人遇到类似的问题么？&lt;/p&gt;

&lt;p&gt;解决方法:
如 &lt;a href="/zhangyuan" class="user-mention" title="@zhangyuan"&gt;&lt;i&gt;@&lt;/i&gt;zhangyuan&lt;/a&gt; 所说，我的 Sinatra 的应用绑定的是&lt;code&gt;127.0.0.1&lt;/code&gt;，所以按 ip 访问不到
启动的时候绑定到&lt;code&gt;0.0.0.0&lt;/code&gt;就好了  &lt;/p&gt;</description>
      <author>allenwei</author>
      <pubDate>Wed, 18 Jan 2012 11:26:31 +0800</pubDate>
      <link>https://ruby-china.org/topics/889</link>
      <guid>https://ruby-china.org/topics/889</guid>
    </item>
    <item>
      <title>RSpec 2.8 发布了， 速度快了 45%</title>
      <description>&lt;p&gt;&lt;a href="http://www.rubyinside.com/rspec-2-8-released-5772.html?utm_source=feedburner&amp;amp;utm_medium=feed&amp;amp;utm_campaign=Feed%3A+RubyInside+%28Ruby+Inside%29" rel="nofollow" target="_blank"&gt;http://www.rubyinside.com/rspec-2-8-released-5772.html?utm_source=feedburner&amp;amp;utm_medium=feed&amp;amp;utm_campaign=Feed%3A+RubyInside+%28Ruby+Inside%29&lt;/a&gt;  &lt;/p&gt;</description>
      <author>allenwei</author>
      <pubDate>Sun, 08 Jan 2012 13:20:59 +0800</pubDate>
      <link>https://ruby-china.org/topics/769</link>
      <guid>https://ruby-china.org/topics/769</guid>
    </item>
  </channel>
</rss>
