Ruby China
  • 社区
  • 招聘
  • Wiki
  • 酷站
  • Gems
  • 注册
  • 登录
@niedhui
高级会员
第 226 位会员 / 2011-11-23

众牛(上海)股权众筹服务有限公司
上海
17 篇帖子 / 77 条回帖
0 关注者
0 正在关注
1 收藏
GitHub Public Repos
  • dotfiles 1

    dotfiles

  • ansibles 0

  • ansible-basic 0

  • solana-program-library 0

    A collection of Solana-maintained on-chain programs

  • liquidator 0

    open source version of a liquidation bot running against solend

  • nervos-hackaton 0

  • polyjuice-provider 0

    Godwoken L2 compatible providers for ethereum library

  • solana 0

    Web-Scale Blockchain for fast, secure, scalable, decentralized apps and marketplaces.

  • docs-cn 0

    TiDB/TiKV/PD documents in Chinese.

  • niedhui 0

More on GitHub
  • 概况
  • 话题
  • 回帖
  • 收藏
  • 正在关注
  • 关注者
  • [长三角][2013年5月11日] Ruby 开发者沙龙 at 2013年05月09日

    @kenshin54 我准备周五晚上开车过去,早上起不来······

  • [长三角][2013年5月11日] Ruby 开发者沙龙 at 2013年05月08日

    上海同学有一起去的吗,组团啊 @kenshin54

  • [上海][2013年5月7日] Ruby Tuesday 活动召集 at 2013年05月06日

    嗯,这次离公司最近了,过去吐个泡~~

  • 新的文艺站 hua.li 上线,适合给有妹子的 geek 用 at 2012年11月14日

    #20 楼 @yangchenyun 额。。。我倒是没想过要不要也送基友一支:)

  • 新的文艺站 hua.li 上线,适合给有妹子的 geek 用 at 2012年11月09日

    不错,下周找个时间买一支

  • 为什么程序员不擅长评估开发时间? at 2012年08月10日

    额。。。是张图

  • 关于 begin expression end 这种用法 at 2012年05月10日

    #6 楼 @saberma 不好意思,主要是好奇 begin..end 这种写法是为了代码组织方便,还是有其他功能,所以没太注意缩进和拼写。 ;)

  • 求解 define_method 中变量的作用域 at 2012年04月24日

    #1 楼 @hisea #3 楼 @wx1452 懂了,谢谢,proc 一直在用,忽略了闭包,binding 这一说了。

  • 你不必这么着急 at 2012年04月20日

    曾经有一段时候我很浮躁,就拿出了一本《佛学入门》……

  • 针对大量数据跑任务 at 2012年04月18日

    先谢谢各位了。我的这个情况逻辑很简单,用 mapreduce 的话好你都找不到要 reduce 啥,内存这个问题到是确实有,一次返回的结果大一些内存就飚上去了。数据分段有什么好的建议吗?因为即使是 mapreduce 也不会一次把数据都取回来吧,我现在就是一个月的一组,以后可能要每周一组了,或者有类似的实现不

  • 针对大量数据跑任务 at 2012年04月17日

    #2 楼 @vkill 现在用的是 mongoid,一次查询如果返回的数据量稍微大一点的话,cursor 移到后面就会变的很慢

  • 针对大量数据跑任务 at 2012年04月17日

    #1 楼 @donnior 现在数据都是存在 mongodb 里面,不到最后,不太想试 Hadoop 啊,总觉得好重的东西:)

  • Ruby China T 恤第一期的赠送名单公布 at 2012年04月16日

    哈哈哈,感谢 ruby china

  • 能不能同时将一个应用部署到两台用户名不同的机器上去? at 2012年04月13日

    在 cap 的文件里, role :app, 'user1@server1', 'user2@server2'

  • 把 mbp 以旧换新了 at 2012年04月12日

    #1 楼 @huobazi 是啊,今天接完电话突然想到要是再忍一段时间,搞不好就能换到最新款了,太贪心啦

  • 我的 linode 今天打不开了, 大家有出现吗? at 2012年04月12日

    我们公司也一样,国内飞快,国外全瘫

  • [求推荐] 写 open api 的工具 at 2012年03月30日

    谢谢大家,找时间一个一个试试

  • Ruby China Android 客户端预览版 at 2012年03月23日

    不错不错,下下来试用~

  • 又拍云存储限时优惠,注册就送 30G 流量啦!(活动已结束) at 2012年03月13日

    等待试用~~

  • 请问社区可不可以组织一下团 textmate? at 2012年03月09日

    tm2 几乎不适合写代码啊,很慢很慢 更新速度也好慢好慢 不过有些新功能倒是很好用的

  • 你们都在使用鼠标吗? (iMac) at 2012年03月02日

    为什么我触摸板又久了就会手指疼。。。

  • [上海][2012年02月21日] RubyTuesday 活动公告 at 2012年02月22日

    签到,在旁边的麦记,吃完就过去

  • 如何在 link_to 内加一个其他 html 标签 at 2012年02月09日

    另外 link_to 可以用 block 的:

    <%= link_to(@profile) do %>
      <strong><%= @profile.name %></strong> -- <span>Check it out!</span>
    <% end %>
    
  • 谈谈今天 ruby-china 的优化 at 2012年02月06日

    @huacnlee 能不能稍微讲一下 Mongoid#cache 文档上说

    Out of the box, Mongoid wraps the MongoDB Ruby Driver's cursor in order to be memory efficient for large queries and data sets. However if you want the query to load all matching documents in memory and return them on n iterations without hitting the database again you may cache a class or criteria:
    

    这个缓存是针对每个 request 的,还是全局的?大体的机制是什么样的?谢谢

  • 程序员之 明明知道是错的还经常做的事 at 2012年01月17日

    #8 楼 @TsingHan 明明知道代码要写测试,却经常懒的写 +1

    #3 楼 @lgn21st 我明明知道自己不吃肉不好,但是就是死活都不吃

  • carrierwave custom name at 2012年01月17日

    #1 楼 @sunzheng91 谢谢 因为 fname = Digest::MD5.hexdigest(self.read) 所以当处理 version 的 name 的时候,self.read 读的是处理过的文件

    def secure_token(length = 16) 
      var = :"@#{mounted_as}_secure_token" 
      model.instance_variable_get(var) or model.instance_variable_set(var, SecureRandom.hex(length / 2)) 
    end
    

    这个就是我最后问的 难道要在 model 加变量来处理?

  • 原来 ruby-china 也可以按 m 键了查看 markdown 语法了 at 2012年01月10日

    我的 safari 也 m,esc 几次后也会变黑

  • 提问要有方法 at 2012年01月09日

    @huacnlee http://ruby-china.org/topics/667 (2 楼) 额。。。我没提问啊,回答的有问题?

  • 诱人的 Pair programming 环境 at 2012年01月09日

    口水

  • ruby-china 源代码管理员账号是什么? at 2012年01月02日

    #3 楼 @Victor 我觉得功能上没区别吧,但这样写更好,简洁,易读:

    def admin?
      Setting.admin_emails.include?(self.email)
    end
    

    我只是把 ruby-china 的源码添上来的,方便找。。。。

  • 上一页
  • 1
  • 2
  • 3
  • 下一页
关于 / RubyConf / Ruby 镜像 / RubyGems 镜像 / 活跃会员 / 组织 / API / 贡献者
由众多爱好者共同维护的 Ruby 中文社区,本站使用 Homeland 构建,并采用 Docker 部署。
服务器由 赞助 CDN 由 赞助
iOS 客户端 / Android 客户端 简体中文 / English