123
 123

Thu 27 November, 2008

Click here to bookmark this link.Channel Image20:23 Rails实例世界(No 3):关于Textile的可视化编辑插件textile_toolbar» 天天红玉世界
关于Textile的可视化编辑插件textile_toolbar

注:好像Firefox不能够访问上面图的链接,而使用浏览器Safari是可以的。
 
使用关于Textile的可视化插件textile_toolbar方法
rails textile_toolbar_demo && cd textile_toolbar_demo
 
ruby script/plugin install git://github.com/pelargir/textile_toolbar.git
rake textile_toolbar:install
 
ruby script/generate scaffold post title:string body:text published:boolean
 
vi app/views/posts/edit.html.erb
<%#= f.text_area :body %>
<%= f.textile_area :body, :rows => 5, :cols => 20 %>
 
vi app/views/layouts/posts.html.erb
<%= stylesheet_link_tag 'scaffold' %>
<%= javascript_include_tag :defaults %>
<%= javascript_include_tag "textile_toolbar.js" %>
 
rake db:migrate && rake db:fixtures:load
 
ruby script/server
 
# http://localhost:3000/posts/<post.id>/edit

add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image18:58 代码世界:逆向循环语句» 天天红玉世界
正向循环语句
(1..5).each do |i|
puts i
end
逆向循环语句
5.downto(1) do |i|
puts i
end
  • 说明
    • 在下面资料的逆向循环语句中,do前面多了一个点。
  • 参考资料
    • http://www.railsrocket.com/articles/looping-backwards-in-ruby

add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image07:40 Rails框架:最有前途的代码测试工具Cucumber» 天天红玉世界
最有前途的代码测试工具Cucumber
  • 说明
    • Cucumber是跨计算机语言的代码测试工具
    • Cucumber是使用本地化语言的代码测试工具
    • Cucumber是集成多种测试工具于一体的工具
    • Cucumber彻底分离测试描述(文字工作者)与描述实现(软件工作者)
    • Cucumber更加人性化,更加语言化,更加简单化
  • Cucumber(中文语言描述)基础讲座系列(即将推出)
    • Cucumber on Rails基本使用过程
    • Cucumber基本概念
    • Cucumber on Rails最简单实例
    • Cucumber on Rails深化实例

add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image01:13 Let *Me* Decide What A Good Password Is!» Joey Gibson's Blog
I have had it with web sites that won’t let me put really secure passwords on my accounts. What do I mean by that? I mean sites that won’t allow anything other than letters and numbers in a password. WTF? I have a whole keyboard full of lovely glyphs to choose from; why limit me [...]
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl

Wed 26 November, 2008

Click here to bookmark this link.Channel Image22:34 慢速软件开发» 梦想风暴
这是一个急三火四的年代,人们很不得一口吃下一个胖子,做软件开发的恨不得一下子就完成一个软件,然后就在家里数钞票。

心急火燎的结果呢?下面的情景是否会让你有种似曾相识的感觉:
* 费了半天努力修改的bug,仔细想来,其实已经在需求明明白白写好了,只是开发时未曾注意到。
* 好容易写好的一段代码,还没来得及向别人炫耀,却发现原来一个好好的功能出了问题,更糟糕的是,根本看不出这两段代码有什么联系。
* 这个bug让你想骂人,因为它居然是其他人修改另一个bug引入的。
* 这个地方有人改过,不过,修改的代码解决的根本不是真正的问题。
* 客户要的是一个小功能,但是对我们来说,加入它无异于重写整个系统。
……

已经有无数人用无数的事实告诉我们,在软件开发中,要付出就趁早,越晚代价越大。当然,我们能看到的大多数例子是在开发的不同阶段,比如需求比开发便宜,开发比测试便宜,测试比维护便宜等等。其实,在开发之中,也是如此,新鲜出炉的代码绝对比那些陈年旧帐更容易修改,不信的话,找一段自己几个月前写的代码理解一下试试。

前面那些似曾相识的场景,多半都是“急”出来的。可现实是,我们需要在后期用更大的精力为前面的“急”买单,所以,为了不给未来的自己挖坑,我们不妨慢一些:
* 仔细了解一下需求,分析需求是不是合理,而不要低着头就开始堆代码。
* 给出一个解决方案时,考虑一下会对已有的代码造成怎样的影响,打破窗户容易,修补难。
* 多花点时间重构,代码上的臭味越到后期显得越刺激。
* 修改bug时,停下来想想什么才是真正的问题,治标不治本的方案只会让人重回梦境。
* 写测试吧!貌似的浪费会让你在后期遇到bug时感激涕零。
……

软件开发其实是一个跟复杂度做斗争的过程,从某种程度来说,复杂度会一直在增长,我们所能做的就是尽可能降低复杂度增长的速度。我曾经和一些朋友说过,前期所做的一切是让我们在后面有更大空间挥霍。慢下来,让我们有时间思考自己的每一步是否迈得是否稳当,稳当的行进,心里才踏实。

这里的慢,实际上,还是为了快,殊途同归。




add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image20:13 配置ActionMailer使用GMail发送邮件» LetRails
这个问题由来已久,比较了一下几种现有的解决方案,最后发现Robert Bousquet的方案是最简单的。 1. Robert只提供了一个源码下载链接,不是很方便,我将它放到了github上: $ script/plugin install git:/...
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image15:02 Rails2.2世界:国际化功能问与答(一)» 天天红玉世界
免费无限存放图片在slide.com!
  • 国际化功能问与答(一):国际化文件
    • 默认国际化文件在哪里?
      $RAILS_ROOT/config/locales
    • 使用什么样语言写国际化文件?
      YAML语言
      或者
      Ruby语言
    • 通常中国大陆中文使用什么国际化文件名称?
      zh-CN.yml
      或者
      zh-CN.rb
    • 默认国际化文件是定义了什么文字语言?
      English
    • 国际化文件最大特点是什么?
      以命名空间为基础结构
    • 一个国际化文件是否可以存在几种语言或者方言(zh-CN,zh-HK,zh-TW)呢?
      可以
    • 一种语言或者一种方言的国际化内容是否可以存放到几个国际化文件呢?
      可以
    • 一个国际化文件名称是否与文件内容相关呢?
      无关

add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image03:53 First Steps into Rails (on the Mac)» O'Reilly News:Ruby
Once you have Rails installed, it's time to explore the foundations of how Rails applications are put together. It's not quite programming yet - it's more looking around to figure out how the pieces fit together.
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image03:53 First Steps into Rails (on the Mac)» O'Reilly News:Ruby
Once you have Rails installed, it's time to explore the foundations of how Rails applications are put together. It's not quite programming yet - it's more looking around to figure out how the pieces fit together.
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image03:53 A Conversation with the Authors of JRuby Cookbook» O'Reilly News:Ruby
Henry Liu and Justin Edelson authors of the just released JRuby Cookbook talk about JRuby, the current state of the Java platform, and some of the compelling benefits of integrating a language like Ruby with the Java platform.
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image03:53 MountainWest RubyConf Sponsorship» James Britt - Code, Content, Caffiene

MountainWest RubyConf, among the most super cool awesome Ruby gatherings around, is looking for sponsors for the 2009 event in Salt Lake City, UT.

You can read the prospectus here. (PDF)

If you or your company is looking to support the Ruby community, and get some solid advertising in front of some of the best geeks in the world, this is for you.

If you know someone or some company who would be interested in sponsoring the conference, please pass this information on.


add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl

Mon 24 November, 2008

Click here to bookmark this link.Channel Image23:36 きょうはなんのひ?» Matzにっき
林明子さんは個人的に好きな絵本画家。 瀬田貞二さんは指輪物語などの翻訳もしてる児童文学家。 子供が親にスカベンジャーハントをしかけるという話。 つまり、手紙に書いてあるヒントに従って、 次の場所に行くとまた手紙があって、というような感じ。 で、その日は両親の10回目の結婚記念日でした。 子供なりのお祝いだったんですね。 上の子がまだ小さかった頃、 この本が大変に面白かったので、 誕生日プレゼントに買ってやったのだが、 その時にはちょっと難しかったようで、 親が思ったほどは楽しまなかったようだった。 しかし、ず..
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image23:33 Apple世界:终于有了合适的中文输入法Fun Input Toy» 天天红玉世界
终于找到了中文输入法Fun Input Toy
  • 安装说明
    • 下载: http://fit.coollittlethings.com/down.php?v=1.9.3_intel
    • 解压文件即双击该文件: FunInputToy_v1.9.3_intel.zip
    • 双击文件: FunInputToy_v1.9.3_intel.pkg
    • 自动重新启动计算机
    • 系统偏好设置 >> 多语言环境 >> 输入法菜单 >> 如上图所示
  • 致谢
    • 非常感谢 kyle 所提供的信息.

add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image18:25 教会、行けず» Matzにっき
Webで一番近い教会(Buena Vista Ward)を検索して、 タクシーで向かったのだが、発見できなかった。 該当する住所にはシェラトンホテルがあった。 なにかの間違いだと思うけど、なにが間違ってたんだろう。 残念だ。
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image18:25 スペースバー» Matzにっき
X61のキーボードにゴミがたまってたんで、掃除してたら スペースバーがはずれた。 なんか元に戻らない。いろいろ苦労してパズルを解くようにしてたら、 とりあえずはまったけど、前より浮いた感じがする。 たまにスペースを取りこぼすし。 どうしたらいいんだろう? キーボード交換するしかない?
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image18:25 Nice Try» Matzにっき
RubyConfのQAセッションで、Rubiniusについて「Nice Try」と発言したら 爆笑された。あまりにも意外なので、正直、ショックを受けた。 後で聞いたら「Nice Try」にはネガティブなニュアンスがあるんだとか。 フランス人と一緒に「そんなの難しいよねえ」とぐちる。 At the QA session in RubyConf, when I stated "Nice Try" on Rubinius, everyone laughed loud. I was even shocked. I meant Rubinius to be a good attempt to reach ideal Ruby, but not there yet. How sad to be a non native speaker.
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image09:11 Mac Recipe Management Programs» halostatue
It’s time to declutter the house. One of the things I want to get rid of are all the recipe magazines and loose recipes that I have. To do this, I need to keep the recipes that I like or want to try. I need a recipe management program. I currently use Yum 2.7.4, which [...]
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image07:10 Autumn, the year’s la...» Projectionist
Autumn, the year’s last, loveliest smile.

William Cullen Bryant


add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl

Sun 23 November, 2008

Click here to bookmark this link.Channel Image19:46 软件世界:消息队列(Messaging Queue)与Ruby语言和Rails框架» 天天红玉世界
消息队列(Messaging Queue)与Ruby语言和Rails框架
  • 服务器与客户端概念
    • 在HTTP概念中,存在浏览器(Client)与网络服务器(Server);
    • 在Queue概念中,也存在客户端软件与服务器软件概念;
  • 参考资料
    • https://computing.llnl.gov/tutorials/parallel_comp/

add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image08:12 Monkeybars at Ruby Manor» James Britt - Code, Content, Caffiene

There’s a nice write-up about recent events at Ruby Manor that describes a talk involving Monkeybars.

I want add a few comments. First, while it is true that using JRuby means some gems do not work, the upside is that you have at your disposal the hojillion1 Java libraries. While it is a goal that all Ruby code, gem or not, work with JRuby (with some caveats about native code), the ability to call into Java libs is a major win. The post mentions that a particualr gem for using Twitter could not be used; I’m fairly sure this is the exact situation Logan Barnett encountered when he started on Twit-and-Twitter for the Java One Script Bowl.

Logan was able to use a Java lib for Twitter, one that (as I recall) offered a more robust API. Big win. So, not to diminish the problem JRuby may have with certain gems, but there are two ways of looking at this: Some gems don’t run (glass 99/100 empty), vs. full use of Java libs (glass overflowing onto the floor and out the door).

Second, Monkeybars was compared (so to speak) with Shoes. No mention was made of Shoes having stability issues (something I’ve seen for myself), but even were it rock-solid there is no way one would want to build a serious app of any complexity. (To fair, I don’t think Shoes was created for that purpose, though some enthusiasts mistake the ease of use as demonstrated in demo apps as something that scales to commercial-grade desktop applications. If and when there is a WYSIWYG editor for Shoes that might change.) I’m deeply skeptical that, for example, JotBot could have been made in Shoes, if only because of the lack of sophisticated components.

However, for those who really REALLY want to build GUI apps that way, good news: Work is afoot to add this to Monkeybars. We hope before too long to allow Monkeybars to offer the best of both worlds.


1 This is a really big number. Really. Big.


add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image07:18 苹果世界:最受欢迎的RSS阅读器NewsGator» 天天红玉世界
最受欢迎的RSS阅读器
  • 安装说明
    • 点击链接: http://tinyurl.com/6g8nd9
    • 把下载的文件NetNewsWire.app移到应用软件目录下
    • 点击该文件NetNewsWire.app,就可以启动该软件
    • 注册一下用户
    • 在所有的Mac OS X机器上,只要有该软件并且有相同的用户,相互间就可以同步本地RSS信息。

add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl

Sat 22 November, 2008

Click here to bookmark this link.Channel Image14:55 The Case Of the Too-Hot Transformer» Joey Gibson's Blog
Picture it. Friday night. 22:45. Outside Atlanta, GA. Cold. The wife and I were watching the final episodes of Season One of Burn Notice. Killer show. From the other room came a howl of consternation. Thomas gave it to me straight, “Dad! Can you check our Internet connection? Every website I try to visit gives [...]
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image08:06 Rails 2.2: i18n, HTTP validators, thread safety, JRuby/1.9 compatibility, docs» Riding Rails - home

Rails 2.2 is finally done after we cleared the last issues from the release candidate program. This release contains an long list of fixes, improvements, and additions that’ll make everything Rails smoother and better, but we also have a number of star player features to parade this time.

Internationalization by default
The most important is that Rails now includes a full-on internationalization framework and that it’s pre-wired from start. The work of the i18n group has been very impressive and it’s great to see that Rails finally ships with a solution in the box that’s both simple and extensible. Great job, guys!

Stronger etag and last-modified support
We’ve also added much better support for HTTP validators in the form of etag and last-modified. Making it so much easier to skip expensive procesesing if the client already has the latest stuff. This also makes it even easier to use Rails with gateway proxies.

Thread safety and a connection pool
Josh Peek has added thread safety to Rails and Nick Sieger from JRuby worked on getting Active Record a proper connection pool. So now all elements of Rails are thread safe, which is a big boon for the JRuby guys in particular. For C Ruby, we still need a bunch of dependent libraries to go non-blocking before it’ll make much of a difference, but work on that is forth coming.

Ruby 1.9 and JRuby compatibility
Jeremy Kemper has been rocking on both Ruby 1.9 and JRuby compatibility. Rails 2.2 is fully compatible with both, but again, there might be supporting libraries and gems that are not. Again, lots of work is going into making everything else fully compatible as well.

Better API docs, great guides
Finally, the last big push has been with the documentation of Rails. Pratik’s docrails project has made immense progress. Not only are the API docs much improved, but we also have a whole new guides section generated from documentation that now lives with the source. A true community project with lots of contributors. I’m sure both those new and old to Rails will greatly appreciate the strong focus on documentation.

To read about all these features and more in details, checkout the Rails 2.2 release notes—another one of those guides from the docrails project.

How to install
As always, you can install Rails 2.2 through RubyGems. We now require RubyGems 1.3.1, so be sure to update that first: gem update --system

Then you can install Rails: gem install rails

If you’re updating an existing application, you can run rake rails:update to get the latest JavaScript files and scripts.

From all of us to all of you, we hope you enjoy this release. It’s a true pleasure to see Rails make such big steps forward once again. Dig in, have fun, and we’ll be back with Rails 2.3 with even more before you know it.


add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image06:55 网站推荐:Ruby和Rails书籍有多少?» 天天红玉世界

Ruby和Rails书籍知多少?


add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image00:11 This Week in Edge Rails» Riding Rails - home

First up this week, a warning for those who don’t closely follow the state of the Rails repository – “edge” really means edge now. The bits for 2.2 are getting locked down for release, and the repository has been forked; for the moment, edge Rails is being identified as 2.3 , though that projected version number might change later. If you’re trying to install almost-released 2.2 bits on your machine, make sure you’re using the 2-2-stable branch, and not edge, which is currently seeing some major changes.

The 2-2-stable code is still seeing changes, but they’re either bug fixes or very small things. This week, that includes fixing a bug in assignment to has_one :through associations , some further tuning of CSRF protection , a fix to handling of checkboxes for Boolean attributes , updating the bundled copies of TZInfo, Prototype, and script.aculo.us, and some Ruby 1.9 compatibility work (though currently full Ruby 1.9 compatibility is targeted for Rails 2.3).

The biggest feature change in the 2.2 branch is the addition of explicit I18n support to newly-generated Rails projects, including a sample locale file, auto-loading all locales in config/locales, and sample settings in config/environment.rb. commit

Also worth noting in 2.2 is a chunk of code removal: a whole mess of special case tests for the SQL Server adapter have been chopped out of the Active Record test cases. That’s because Ken Collins has done tremendous work in making the SQL Server adapter work the way that Rails expects data adapters to work, giving us a big step in the area of backend portability. commit

On the actual edge code (the master branch in the repository), there’s a lot more action. With that branch just opened, some pent-up code has been checked in, and some big changes are being made. It’s an exciting time, and edge is definitely worth checking out. Here are some of the most notable changes in the past week.

One big set of changes has come from Jeremy Kemper, who has been overhauling the internal Rails testing to switch from Test::Unit::TestCase to ActiveSupport::TestCase. This work also includes requiring Mocha to test Rails (in the 2.2 code, some tests are skipped if you don’t have Mocha installed) and generally making the Rails testing strategy (both within core and for generated applications) more consistent moving forward.

If you’re one of the people who has always been bothered by the special-case naming of application.rb, rejoice! It’s been reworked to be application_controller.rb in the edge code. More info here and here . commit

Rails 2.3 will introduce the notion of default scopes : similar to named scopes, but applying to all named scopes or find methods within the class. For example, you can write default_scope :order => 'name ASC' and any time you retrieve records from that class they’ll come out sorted by name (unless you override the option, of course). commit

A lot of folks have adopted the notion of using try() to attempt operations on objects – Here’s Chris Wanstrath’s blog post introducing it. It’s especially helpful in views where you can avoid nil-checking by writing code like <%= @person.try(:name) %>. Well, now it’s baked right into Rails. commit

Also new on the syntactic sugar front is Enumerable#none? to check that none of the elements match the supplied block. commit

The render method has been getting smarter over the years, and it’s going to be even smarter in 2.3. If you have an object or a collection and the naming matches up, you can now just do <% render @article %> or <% render @articles %> and things will just work. Ryan Daigle has some more examples on this. commit

On a somewhat similar note, render_component goes from “deprecated” to “nonexistent” in 2.3. If you still need it, you can install the plugin . commit

The autolink helper has been refactored to make it a bit less messy and more intuitive. commit commit

There’s a fix to a memory leak connected to thread safety and asset tags, that could bite sites that were referencing a lot of external images. Aaron Batalion contributed the fix, as well as a blog post explaining the issue. commit and commit

Finally, it’s worth mentioning that some controversy has erupted over a change made to the 2.2 code five months ago – the addition of Array#second through Array#tenth as aliases for Array#[1] through Array#[9]. Without taking a stand on the controversy (I’ve done that elsewhere), I’ll just note that the most recent edge checkin as I write this trims this down to only support Array#second through Array#fifth – and uses the savings in overhead to implement Array#forty-two. commit


add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image00:11 iPhone OS 2.2 - Meh, So Far» Joey Gibson's Blog
I happened to be up and working for the man at 2:00 this morning when I saw a note on Twitter saying that Apple had released version 2.2 of the iPhone OS. Being the fanboy that I am, I immediately started the update process. The whole thing, from first click to iPhone ready-to-use, took about [...]
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl

Fri 21 November, 2008

Click here to bookmark this link.Channel Image15:33 运作» nonocast ! 真诚原是一种需要坚强不屈的品质
子东:
比方说我给你举个例子,最近我一个朋友讲到四万亿眼睛都发红,可是,那些做企业的吧,
比方说他是生产服装的,他说他只花很少的精力很少的钱去关心这个服装做的怎么样,
他说你做的怎么样做什么服装是他考虑的十分之一都不到的事情,
那重要的是什么呢,因为你的服装不能去卖给老百姓,因为赚不了钱的,那你也不能出国的,因为外国人都是很抠的,
他整天要检查你,所以最好的赚钱的方法就是卖给,比方说,你是一个国营的大饭店,你一订订5000套,
那我只要搞定那个订货的人,那我这5000套怎么做,价钱可以高,东西又可以做的次。

所以他最大的精力就用在建立一个关系网,就是什么人可以给我订单,
他不需要科研费,生产费是压到最低。什么东西都弄到最低,最大的费用就是关系费。
我关键只要订单,你可以从这样一个小的case你就可以知道事情是怎么在运作,
那么这些负责国营企业,各种各样官员,他随便都可以做,你们十个工厂都在做衣服,
我明明知道你们做的好啊,可是他给我好处了,我为什么要订你的衣服,至于衣服怎么样不是随便穿嘛,
所以他们之间的这种合作关系就使得质量问题变得完全不重要,这在衣服是没危险性哦,这到地铁就有危险性了。

文道:
所以在中国呢,很多人都知道,很多商人都知道,要赚钱,最好赚的是什么钱,就是项目,而且是公家的项目。
你跟外国人做买卖,那是市场竞争,你跟中国老百姓做买卖,就像你讲的,老百姓没多少钱让你赚,
但是你赚政府的钱,那是多大的一笔钱啊,而且政府的钱赚的就比较容易,
我们想想所谓贪污是什么概念,贪污其实是一个做生意的人他必须要面对的一个诱惑,
而且那个诱惑实在太大了,因为你想想看,如果就像你刚才讲的那个例子,我如果花心思做好这个衣服,
去研究这个市场,去做好风险的计算,怎么样去跟人家竞争,那是一个很困难的事情,
但如果反过来,我天天想着,负责这个项目的领导他爱什么,李书记我该给他个什么。
我天天琢磨这事,相比之下要容易多了,那你相对来讲,你好像一下子表面付出了要来贿赂的款项,
但是你耗费的各种精力什么加起来,你是划算多了。

所以中国现在我担心的就是贪污变成一种路径依赖,他是惯性的,从人性的角度来讲,
他是一个最容易赚钱,最容易做生意的方法,如果我们说资本主义相信理性的话,没有一个理性的人不会不想去贪污。

文涛:
所以有的时候就出现一个两难,就是本身照那种纯粹的市场论来讲,政府应该管的越少越好......
,balabalabala,貌似有些不和谐,开始转移话题...懂的


add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image11:54 setup my new mac» Suave's Blog
昨天终于买到新款 macbook pro, 还是个定制版(MB470 硬盘换成 7200转, 据说是从HK订制出货比较快, 所以商家全部采用订制的方式进货). 顺便推荐一下商家 - 苹果家园, 挺靠谱的! 开机先装一通必备软...
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image06:05 Installing Rails on Ubuntu Hardy Heron (Server)» O'Reilly News:Ruby
Want to install a Rails development environment on a bare-bones Ubuntu server setup? It's not that hard.
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image06:05 Installing Rails on Ubuntu Hardy Heron (Server)» O'Reilly News:Ruby
Want to install a Rails development environment on a bare-bones Ubuntu server setup? It's not that hard.
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image06:05 Installing Rails on Hardy Heron (Desktop)» O'Reilly News:Ruby
There are way too many operating systems and choices within those operating systems to provide a straightforward explanation of installing Rails. To solve that, I'm creating screencasts that show how to install Rails, demonstrating both how to do it and that it actually is possible.
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Click here to bookmark this link.Channel Image06:05 Installing Rails on Hardy Heron (Desktop)» O'Reilly News:Ruby
There are way too many operating systems and choices within those operating systems to provide a straightforward explanation of installing Rails. To solve that, I'm creating screencasts that show how to install Rails, demonstrating both how to do it and that it actually is possible.
add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl

Thu 20 November, 2008

Click here to bookmark this link.Channel Image15:05 Rails世界:Ruby软件包和Rails插件的使用趋势» 天天红玉世界
Click here to bookmark this link.Channel Image05:09 Why Ramaze? And more. Ramaze by Example» James Britt - Code, Content, Caffiene

With king of the hill Rails chugging along, and up-and-comer Merb picking up steam, why bother with Ramaze?

The number one thing that makes Ramaze stand out from the crowd is that you write very little code and you write it all yourself. No generators.

...

Before Rails, people wrote lots and lots of code when making a web app, and they did it over and over as they did web app after web app. With each new app, they would spend time “ramping up” with just the base application before they got into the real meat of the matter, the core functionality which varied from client to client, application to application. Rails and Merb and their ilk try to make your life easier by generating this “lots and lots of code” for you, so you don’t have to spend time repeating the motions of getting the skeleton of your application coded.

Ramaze takes a different approach. It asks: How about we dump the “lots and lots of code” part altogether? This way, you get the benefit of nearly nil ramp up time, without the gaping jaw effect that hits you after you run a code generator script and sit staring at the big filetree that just sprouted out of the ground (think Jack and the Beanstalk).

Ramaze by Example


add to del.icio.us add to del.icio.us. look up in del.icio.us.   add to furl.net add to furl
Sources