<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <title>jean</title>
    <link>https://ruby-china.org/jean</link>
    <description>制胜之道，在人而不在器</description>
    <language>en-us</language>
    <item>
      <title>为什么开店的时候你不用淘宝而选择自己搭建商城？</title>
      <description>&lt;p&gt;目前来看淘宝商城已经很完善了，有什么理由不用呢？很好奇，欢迎分享经验！&lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Mon, 06 Aug 2012 11:05:41 +0800</pubDate>
      <link>https://ruby-china.org/topics/4759</link>
      <guid>https://ruby-china.org/topics/4759</guid>
    </item>
    <item>
      <title>如何在 github 上迅速翻到项目的 first commit?</title>
      <description>&lt;p&gt;如何在 github 上迅速翻到项目的 first commit？一页一页的翻真是累死了。&lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Thu, 02 Aug 2012 15:52:36 +0800</pubDate>
      <link>https://ruby-china.org/topics/4706</link>
      <guid>https://ruby-china.org/topics/4706</guid>
    </item>
    <item>
      <title>如何快速安装脚本中 require 的库？</title>
      <description>&lt;p&gt;用 Sinatra 写了个小东西，require 了一些第三方的库，如何快速安装？
rails 有 GEMFILE 可以很方便的 bundle install 一下完事儿。但不是所有项目都用 rails 的，请高人分享下经验，谢谢！  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Thu, 12 Jul 2012 22:00:18 +0800</pubDate>
      <link>https://ruby-china.org/topics/4280</link>
      <guid>https://ruby-china.org/topics/4280</guid>
    </item>
    <item>
      <title>做一个下载服务，如何统计用户流量计费？</title>
      <description>&lt;p&gt;打算使用 amazon s3 来做，不知道有没有相关的文章，或者案例可以参考一下？谢谢  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Thu, 14 Jun 2012 18:28:32 +0800</pubDate>
      <link>https://ruby-china.org/topics/3814</link>
      <guid>https://ruby-china.org/topics/3814</guid>
    </item>
    <item>
      <title>有比较好的文章发布？</title>
      <description>&lt;p&gt;有的项目需要发布一些文章和新闻，我现在是自己写的代码来管理和发布，但我想这样很普遍的需求，可能有个 gem 存在？  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Thu, 31 May 2012 09:48:58 +0800</pubDate>
      <link>https://ruby-china.org/topics/3570</link>
      <guid>https://ruby-china.org/topics/3570</guid>
    </item>
    <item>
      <title>Linux T 恤免费发</title>
      <description>&lt;p&gt;几年前人还比较闲的时候做的，卖掉了一些，还剩点儿衣服在自己的手里。
这几天看见社区在派送衣服，决定搭车把我手里的存货也免费派送了，全当宣传 linux 了，不过运费自理，因为我这没有人赞助啊:)&lt;/p&gt;

&lt;p&gt;&lt;img src="http://network38.zhejiangok.net/taobao/linux/body.jpg" title="" alt="T1"&gt; &lt;/p&gt;

&lt;p&gt;&lt;img src="http://network38.zhejiangok.net/taobao/linux/body1.jpg" title="" alt="T2"&gt; &lt;/p&gt;

&lt;p&gt;&lt;img src="http://network38.zhejiangok.net/taobao/linux/bodyback.jpg" title="" alt="T3"&gt; &lt;/p&gt;

&lt;p&gt;我从北京发，邮费在 8-15 元，北京市区的 8，外地一般是 15（港澳台除外）&lt;/p&gt;

&lt;p&gt;衣服还剩少量 XL 号，和不少 L 号的&lt;/p&gt;

&lt;p&gt;需要的直接在这里付款吧，付款说明写上自己的地址和衣服的尺寸及自己的手机号号码，或者发到我的邮箱 jeantoe at gmail &lt;/p&gt;

&lt;p&gt;&lt;a href="https://me.alipay.com/zhangyiqun" rel="nofollow" target="_blank"&gt;https://me.alipay.com/zhangyiqun&lt;/a&gt;  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Thu, 19 Apr 2012 19:25:21 +0800</pubDate>
      <link>https://ruby-china.org/topics/2738</link>
      <guid>https://ruby-china.org/topics/2738</guid>
    </item>
    <item>
      <title>有没有编辑 table 的 js 库？</title>
      <description>&lt;p&gt;网页中有一个 table，table 里面存放了一些数据，每一行后面都有一个编辑的按钮，点击编辑后就开始编辑当前行的数据。
记得有个 jquery 的插件，忘了是什么了，有知道的朋友麻烦分享下，谢了！  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Wed, 18 Apr 2012 16:34:50 +0800</pubDate>
      <link>https://ruby-china.org/topics/2690</link>
      <guid>https://ruby-china.org/topics/2690</guid>
    </item>
    <item>
      <title>How to use bundler behind a proxy?</title>
      <description>&lt;p&gt;不知道淘宝那个 gem 服务器是不是有限速，下载起来还不如挂着代理去下载国外的源快&lt;/p&gt;

&lt;p&gt;&lt;a href="http://stackoverflow.com/questions/3877055/how-to-use-bundler-behind-a-proxy" rel="nofollow" target="_blank"&gt;http://stackoverflow.com/questions/3877055/how-to-use-bundler-behind-a-proxy&lt;/a&gt;  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Sun, 15 Apr 2012 10:07:08 +0800</pubDate>
      <link>https://ruby-china.org/topics/2615</link>
      <guid>https://ruby-china.org/topics/2615</guid>
    </item>
    <item>
      <title>有人用 Bootstrap-IE6 做过东西么？</title>
      <description>&lt;p&gt;github 上才 100 多人 watch 估计用的人很少吧 &lt;a href="https://github.com/empowering-communities/Bootstrap-IE6" rel="nofollow" target="_blank"&gt;https://github.com/empowering-communities/Bootstrap-IE6&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;如果有人在用，请分享下地址，我想体验下效果，谢了  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Fri, 13 Apr 2012 19:29:19 +0800</pubDate>
      <link>https://ruby-china.org/topics/2584</link>
      <guid>https://ruby-china.org/topics/2584</guid>
    </item>
    <item>
      <title>数据库异地提速？</title>
      <description>&lt;p&gt;哈喽各位，具体情形是这样：站点和用户数据库（使用 MYSQL）都存放在国外，随着业务的发展在国内也有的很多的客户，这就出现了问题，国内的用户使用起来体验非常差，因为速度太慢了。这种情况下有什么解决的良策么？&lt;/p&gt;

&lt;p&gt;我已知的两种方案不太靠谱
1.MYSQL 主从，如果单纯读取的话不错，但实际上用户对增改都有需求。
2.MYSQL 互为主从，太危险，以大陆的网络状况，数据的一致性有很大的隐患。
主：国外数据库 
从：国内数据库&lt;/p&gt;

&lt;p&gt;问题描述完毕，插个花边新闻，gmail 就很牛逼，他在北京的节点（203.208.46.181）访问起来速度飕飕的，而实际上它应该没有把用户数据放在国内吧。  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Fri, 30 Mar 2012 16:41:00 +0800</pubDate>
      <link>https://ruby-china.org/topics/2282</link>
      <guid>https://ruby-china.org/topics/2282</guid>
    </item>
    <item>
      <title>求一小段 C++ 代码 (WinExec)，超级简单</title>
      <description>&lt;p&gt;客户端用.net 开发好了，然后用了&lt;a href="http://hi.baidu.com/it772/blog/item/4f449b34764eb3d1a2cc2b5a.html" rel="nofollow" target="_blank" title=""&gt;这个办法&lt;/a&gt; 让用户不装.net 也可以运行，问题在于他的那段 C++ 代码是不好使的，求一段好使的 C++ 代码让我能够调用自己的程序，感谢~
&lt;code&gt;LPCTSTR path="SOFTWARE\\Microsoft\\.NETFramework\\v2.0.50727";&lt;/code&gt;
"const char *" 类型的值不能用于初始化 "LPCTSTR" 类型的实体  &lt;/p&gt;

&lt;p&gt;如果米有人帮助的话我就只好用 python 然后 py2exe 去调用了，蛋疼啊  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Mon, 26 Mar 2012 21:32:06 +0800</pubDate>
      <link>https://ruby-china.org/topics/2145</link>
      <guid>https://ruby-china.org/topics/2145</guid>
    </item>
    <item>
      <title>分享一 GTD 开源项目</title>
      <description>&lt;p&gt;Tracks is a web-based application to help you implement David Allen’s Getting Things Done™ methodology. It was built using Ruby on Rails, and comes with a built-in webserver (WEBrick), so that you can run it on your own computer if you like. It can be run on any platform on which Ruby can be installed, including Mac OS X, Windows XP and Linux. Tracks is Open Source, free and licensed under the GNU GPL.&lt;/p&gt;

&lt;p&gt;&lt;img src="http://getontracks.org/images/screens/tracks_home_thumb.png" title="" alt="preview"&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="http://getontracks.org/" rel="nofollow" target="_blank"&gt;http://getontracks.org/&lt;/a&gt;  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Sun, 25 Mar 2012 14:24:15 +0800</pubDate>
      <link>https://ruby-china.org/topics/2115</link>
      <guid>https://ruby-china.org/topics/2115</guid>
    </item>
    <item>
      <title>有开源的网址导航产品么？</title>
      <description>&lt;p&gt;需求很简单：展示一些网站，配上简单的说明介绍&lt;/p&gt;

&lt;p&gt;谢谢~  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Sun, 25 Mar 2012 14:21:04 +0800</pubDate>
      <link>https://ruby-china.org/topics/2114</link>
      <guid>https://ruby-china.org/topics/2114</guid>
    </item>
    <item>
      <title>国内有类似于 UserVoice 的产品么？</title>
      <description>&lt;p&gt;原版网站速度太慢了，也不太符合国人的习惯，这产品也出来很久了，不知道国内有没有类似的替代品？  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Fri, 23 Mar 2012 19:25:28 +0800</pubDate>
      <link>https://ruby-china.org/topics/2089</link>
      <guid>https://ruby-china.org/topics/2089</guid>
    </item>
    <item>
      <title>Advice From An Old Programmer</title>
      <description>&lt;p&gt;The post from &lt;a href="http://learnpythonthehardway.org/book/advice.html" rel="nofollow" target="_blank"&gt;http://learnpythonthehardway.org/book/advice.html&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;You've finished this book and have decided to continue with programming. Maybe it will be a career for you, or maybe it will be a hobby. You'll need some advice to make sure you continue on the right path, and get the most enjoyment out of your newly chosen activity.&lt;/p&gt;

&lt;p&gt;I've been programming for a very long time. So long that it's incredibly boring to me. At the time that I wrote this book, I knew about 20 programming languages and could learn new ones in about a day to a week depending on how weird they were. Eventually though this just became boring and couldn't hold my interest anymore. This doesn't mean I think programming is boring, or that you will think it's boring, only that I find it uninteresting at this point in my journey.&lt;/p&gt;

&lt;p&gt;What I discovered after this journey of learning is that it's not the languages that matter but what you do with them. Actually, I always knew that, but I'd get distracted by the languages and forget it periodically. Now I never forget it, and neither should you.&lt;/p&gt;

&lt;p&gt;Which programming language you learn and use doesn't matter. Do not get sucked into the religion surrounding programming languages as that will only blind you to their true purpose of being your tool for doing interesting things.&lt;/p&gt;

&lt;p&gt;Programming as an intellectual activity is the only art form that allows you to create interactive art. You can create projects that other people can play with, and you can talk to them indirectly. No other art form is quite this interactive. Movies flow to the audience in one direction. Paintings do not move. Code goes both ways.&lt;/p&gt;

&lt;p&gt;Programming as a profession is only moderately interesting. It can be a good job, but you could make about the same money and be happier running a fast food joint. You're much better off using code as your secret weapon in another profession.&lt;/p&gt;

&lt;p&gt;People who can code in the world of technology companies are a dime a dozen and get no respect. People who can code in biology, medicine, government, sociology, physics, history, and mathematics are respected and can do amazing things to advance those disciplines.&lt;/p&gt;

&lt;p&gt;Of course, all of this advice is pointless. If you liked learning to write software with this book, you should try to use it to improve your life any way you can. Go out and explore this weird wonderful new intellectual pursuit that barely anyone in the last 50 years has been able to explore. Might as well enjoy it while you can.&lt;/p&gt;

&lt;p&gt;Finally, I'll say that learning to create software changes you and makes you different. Not better or worse, just different. You may find that people treat you harshly because you can create software, maybe using words like "nerd". Maybe you'll find that because you can dissect their logic that they hate arguing with you. You may even find that simply knowing how a computer works makes you annoying and weird to them.&lt;/p&gt;

&lt;p&gt;To this I have just one piece of advice: they can go to hell. The world needs more weird people who know how things work and who love to figure it all out. When they treat you like this, just remember that this is your journey, not theirs. Being different is not a crime, and people who tell you it is are just jealous that you've picked up a skill they never in their wildest dreams could acquire.&lt;/p&gt;

&lt;p&gt;You can code. They cannot. That is pretty damn cool.  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Thu, 08 Mar 2012 21:31:21 +0800</pubDate>
      <link>https://ruby-china.org/topics/1719</link>
      <guid>https://ruby-china.org/topics/1719</guid>
    </item>
    <item>
      <title>讨论关于桌面 (C/S) 应用开发？</title>
      <description>&lt;p&gt;&lt;strong&gt;作为一个极其懒惰的家伙，我一直在寻找靠谱的跨平台方案以减少自己的代码量。&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;首先把 JAVA 放弃了，开发周期长，东西也比较丑陋，还得额外跑个虚拟机
然后考虑使用 ruby，但是发现主流基本都在移动开发和 WEB 上，桌面应用的方案都很老了，未来估计也不打算更新神马的。&lt;/p&gt;

&lt;p&gt;绕了一圈儿，觉得还是 C＃ FOR WIN 和 OBC FOR MAC 比较靠谱，虽然代码量大了点，但从长远看稳定性更有保障。&lt;/p&gt;

&lt;p&gt;不知道各位有没有什么更好的视野？&lt;/p&gt;

&lt;p&gt;感谢。&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;UPDATE 大获儿推荐的几种方案 - 2012/02/29&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;程序核心需求：一个客户端，连接到 SERVER 后将加密用户联网通信的数据。原理类似于敏感词叫未批恩。&lt;/p&gt;

&lt;p&gt;方案
C# with winform
Mono+Qt
Qt
Python with qt
C++
Delphi&lt;/p&gt;

&lt;p&gt;从学习曲线和时间投入所产生的价值来看，Python with qt 和 C# 完胜。&lt;/p&gt;

&lt;p&gt;Ruby 底层的库看起来不如 python 丰富且年代久远，而 python 的方案则一搜一大把马上开心死了。
我也就开发一个桌面应用，平时开发手机 (OBC) 和 WEB(ROR) 领域最多，学 C++ 或 Delphi 有点蛋疼，人生苦短。&lt;/p&gt;

&lt;p&gt;现在倾向于使用 Python with qt，社区里的人基本都有过其他语言开发经验，求拓宽视野欢迎各种吐槽啊，谢谢，谢谢～  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Tue, 28 Feb 2012 12:58:00 +0800</pubDate>
      <link>https://ruby-china.org/topics/1467</link>
      <guid>https://ruby-china.org/topics/1467</guid>
    </item>
    <item>
      <title>对于各种水平的同学，该如何学习及提高自身 Ruby on Rails 实力?</title>
      <description>&lt;p&gt;最近为了巩固提高自身水平，开始翻阅 rails 方面的书籍，发现的前言非常清晰的解释说明了身处任一阶段的读者应该如何学习提高自身水平。所有想在 rails 领域发展的同学都应该仔细看看。&lt;/p&gt;

&lt;p&gt;最后一段解答了月经帖，rails 适合做企业级开发吗这个蛋疼的问题。&lt;/p&gt;

&lt;p&gt;The Rails Tutorial contains integrated tutorials not only for Rails, but also for the underlying Ruby language, the RSpec testing framework, HTML, CSS, a small amount of JavaScript, and even a little SQL. This means that, no matter where you currently are in your knowledge of web development, by the time you finish this tutorial you will be ready for more advanced Rails resources, as well as for the more systematic treatments of the other subjects mentioned. It also means that there’s a lot of material to cover; if you don’t already have experience programming computers, you might find it overwhelming. The comments below contain some suggestions for approaching the Rails Tutorial depending on your background.&lt;/p&gt;

&lt;p&gt;对于所有读者：One common question when learning Rails is whether to learn Ruby first. The answer depends on your personal learning style and how much programming experience you already have. If you prefer to learn everything systematically from the ground up, or if you have never programmed before, then learning Ruby first might work well for you, and there are several book recommendations in this section to get you started. On the other hand, many beginning Rails developers are excited about making web applications, and would rather not slog through a 500-page book on pure Ruby before ever writing a single web page. Moreover, the subset of Ruby needed by Rails developers is different from what you’ll find in a pure-Ruby introduction, whereas the Rails Tutorial focuses on just that subset. If your primary interest is making web applications, I recommend starting with the Rails Tutorial and then reading a book on pure Ruby next. It’s not an all-or-nothing proposition, though: if you start reading the Rails Tutorial and feel your lack of Ruby knowledge holding you back, feel free to switch to a Ruby book and come back when you feel ready. You might also consider getting a taste of Ruby by following a short online tutorial, such as can be found at TryRuby.3&lt;/p&gt;

&lt;p&gt;Another common question is whether to use tests from the start. As noted in the introduction, the Rails Tutorial uses test-driven development (also called test-first development), which in my view is the best way to develop Rails applications, but it does introduce a substantial amount of overhead and complexity. If you find yourself getting bogged down by the tests, I suggest either skipping them on a first reading or (even better) using them as a tool to verify your code’s correctness without worrying about how they work. This latter strategy involves creating the necessary test files (called specs) and filling them with the test code exactly as it appears in the book. You can then run the test suite (as described in Chapter 5) to watch it fail, then write the application code as described in the tutorial, and finally re-run the test suite to watch it pass.&lt;/p&gt;

&lt;p&gt;零基础：The Rails Tutorial is not aimed principally at beginning programmers, and web applications, even relatively simple ones, are by their nature fairly complex.4 If you are completely new to web programming and find the Rails Tutorial too difficult, I suggest learning the basics of HTML and CSS and then giving the Rails Tutorial another go. (Unfortunately, I don’t have a personal recommendation here, but Head First HTML looks promising, and one reader recommends CSS: The Missing Manual by David Sawyer McFarland.) You might also consider reading the first few chapters of Beginning Ruby by Peter Cooper, which starts with sample applications much smaller than a full-blown web app. That said, a surprising number of beginners have used this tutorial to learn web development, so I suggest giving it a try, and I especially recommend the Rails Tutorial screencast series5 to give you an“over-the-shoulder”look at Rails software development. &lt;/p&gt;

&lt;p&gt;有开发经验但是没有 WEB 领域开发经验：Your previous experience means you probably already understand ideas like classes, methods, data structures, etc., which is a big advantage. Be warned that if your background is in C/C++ or Java, you may find Ruby a bit of an odd duck, and it might take time to get used to it; just stick with it and eventually you’ll be fine. (Ruby even lets you put semicolons at the ends of lines if you miss them too much.) The Rails Tutorial covers all the web-specific ideas you’ll need, so don’t worry if you don’t currently know a PUT from a POST.&lt;/p&gt;

&lt;p&gt;Experienced web developers new to Rails: You have a great head start, especially if you have used a dynamic language such as PHP or (even better) Python. The basics of what we cover will likely be familiar, but test-driven development may be new to you, as may be the structured REST style favored by Rails. Ruby has its own idiosyncrasies, so those will likely be new, too.&lt;/p&gt;

&lt;p&gt;RUBY 程序员：The set of Ruby programmers who don’t know Rails is a small one nowadays, but if you are a member of this elite group you can fly through this book and then move on to The Rails 3 Way by Obie Fernandez. &lt;/p&gt;

&lt;p&gt;RAILS 新手：You’ve perhaps read some other tutorials and made a few small Rails apps yourself. Based on reader feedback, I’m confident that you can still get a lot out of this book. Among other things, the techniques here may be more up-to-date than the ones you picked up when you originally learned Rails. &lt;/p&gt;

&lt;p&gt;有经验的 RAILS 开发者：This book is unnecessary for you, but many experienced Rails developers have expressed surprise at how much they learned from this book, and you might enjoy seeing Rails from a different perspective. &lt;/p&gt;

&lt;p&gt;After finishing the Ruby on Rails Tutorial, I recommend that experienced programmers read The Well-Grounded Rubyist by David A. Black, which is an excellent in-depth discussion of Ruby from the ground up, or The Ruby Way by Hal Fulton, which is also fairly advanced but takes a more topical approach. Then move on to The Rails 3 Way to deepen your Rails expertise.&lt;/p&gt;

&lt;p&gt;At the end of this process, no matter where you started, you will be ready for the more intermediate-to-advanced Rails resources. Here are some I particularly recommend:&lt;/p&gt;

&lt;p&gt;RailsCasts by Ryan Bates: Excellent (mostly) free Rails screencasts
PeepCode: Excellent commercial screencasts
Code School: Interactive programming courses
Rails Guides: Good topical and up-to-date Rails references.
RailsCasts by Ryan Bates: Did I mention RailsCasts? Seriously: RailsCasts.&lt;/p&gt;

&lt;p&gt;Rails 能做企业级应用吗？
Before moving on with the rest of the introduction, I’d like to take a moment to address the one issue that dogged the Rails framework the most in its early days: the supposed inability of Rails to“scale”—i.e., to handle large amounts of traffic. Part of this issue relied on a misconception; you scale a site, not a framework, and Rails, as awesome as it is, is only a framework. So the real question should have been, “Can a site built with Rails scale?”In any case, the question has now been definitively answered in the affirmative: some of the most heavily trafficked sites in the world use Rails. Actually doing the scaling is beyond the scope of just Rails, but rest assured that if your application ever needs to handle the load of Hulu or the Yellow Pages, Rails won’t stop you from taking over the world.  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Wed, 22 Feb 2012 11:05:56 +0800</pubDate>
      <link>https://ruby-china.org/topics/1360</link>
      <guid>https://ruby-china.org/topics/1360</guid>
    </item>
    <item>
      <title>How to Signing iPhone Configuration XML Profile with Ruby on Rails?</title>
      <description>&lt;p&gt;使用 openssl 命令行就可以 sign 出正常的.mobileconfig file，但是使用 ruby 却不行&lt;/p&gt;
&lt;pre class="highlight ruby"&gt;&lt;code&gt;&lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;mobile_config&lt;/span&gt;
  &lt;span class="n"&gt;ssl_key_str&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="no"&gt;File&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;read&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="no"&gt;Rails&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;root&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="s2"&gt;"site.key"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; 
  &lt;span class="n"&gt;ssl_key&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="no"&gt;OpenSSL&lt;/span&gt;&lt;span class="o"&gt;::&lt;/span&gt;&lt;span class="no"&gt;PKey&lt;/span&gt;&lt;span class="o"&gt;::&lt;/span&gt;&lt;span class="no"&gt;RSA&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;new&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;ssl_key_str&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

  &lt;span class="n"&gt;ssl_cert_str&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="no"&gt;File&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;read&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="no"&gt;Rails&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;root&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="s2"&gt;"site.crt"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
  &lt;span class="n"&gt;ssl_cert&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="no"&gt;OpenSSL&lt;/span&gt;&lt;span class="o"&gt;::&lt;/span&gt;&lt;span class="no"&gt;X509&lt;/span&gt;&lt;span class="o"&gt;::&lt;/span&gt;&lt;span class="no"&gt;Certificate&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;new&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;ssl_cert_str&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

  &lt;span class="n"&gt;profile&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="no"&gt;File&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;read&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"/Users/zhang/Desktop/no_sign.mobileconfig"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

  &lt;span class="n"&gt;signed_profile&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="no"&gt;OpenSSL&lt;/span&gt;&lt;span class="o"&gt;::&lt;/span&gt;&lt;span class="no"&gt;PKCS7&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;sign&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;ssl_cert&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;ssl_key&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;[],&lt;/span&gt; &lt;span class="no"&gt;OpenSSL&lt;/span&gt;&lt;span class="o"&gt;::&lt;/span&gt;&lt;span class="no"&gt;PKCS7&lt;/span&gt;&lt;span class="o"&gt;::&lt;/span&gt;&lt;span class="no"&gt;BINARY&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

  &lt;span class="n"&gt;send_file&lt;/span&gt; &lt;span class="n"&gt;signed_profile&lt;/span&gt;
&lt;span class="k"&gt;end&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;原理参考了这篇文章
&lt;a href="http://www.rootmanager.com/iphone-ota-configuration/iphone-ota-setup-with-signed-mobileconfig.html" rel="nofollow" target="_blank"&gt;http://www.rootmanager.com/iphone-ota-configuration/iphone-ota-setup-with-signed-mobileconfig.html&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;在谷歌上搜到一个解决途径，但是不好使
&lt;a href="http://stackoverflow.com/questions/4446247/signing-iphone-configuration-xml-profile-with-ruby-on-rails" rel="nofollow" target="_blank"&gt;http://stackoverflow.com/questions/4446247/signing-iphone-configuration-xml-profile-with-ruby-on-rails&lt;/a&gt;&lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Mon, 16 Jan 2012 14:44:31 +0800</pubDate>
      <link>https://ruby-china.org/topics/872</link>
      <guid>https://ruby-china.org/topics/872</guid>
    </item>
    <item>
      <title>JSON with Ruby and Rails</title>
      <description>&lt;p&gt;JSON is a beautiful format for storing objects as human readable text. It’s succeeded where XML has failed. Not only is it not shit, it’s actually quite good! But don’t just take my word for it, have a look at some of the “cool” ways you can generate and consume JSON.&lt;/p&gt;

&lt;p&gt;&lt;a href="http://mike.bailey.net.au/2011/02/json-with-ruby-and-rails/" rel="nofollow" target="_blank"&gt;http://mike.bailey.net.au/2011/02/json-with-ruby-and-rails/&lt;/a&gt;  &lt;/p&gt;</description>
      <author>jean</author>
      <pubDate>Sat, 31 Dec 2011 11:08:10 +0800</pubDate>
      <link>https://ruby-china.org/topics/671</link>
      <guid>https://ruby-china.org/topics/671</guid>
    </item>
  </channel>
</rss>
