Ruby China
  • 社区
  • 招聘
  • Wiki
  • 酷站
  • Gems
  • 注册
  • 登录
Zete
@luikore
高级会员
第 2880 位会员 / 2012-07-16

55 篇帖子 / 3423 条回帖
245 关注者
6 正在关注
32 收藏
GitHub Public Repos
  • triez 140

    fast, efficient, unicode aware HAT trie with prefix / suffix support for Ruby

  • rsec 78

    Parser / Regexp Combinator For Ruby

  • regexp_optimized_union 11

    Regexp.optimized_union(word_list, regexp_options) generates optimized regexp for matching union o...

  • zscan 9

    Improved string scanner

  • stimulus-bind 9

    Enable simple data binding for stimulusjs

  • vscode-hypertab 3

    The Missing Tab Completion for VS Code

  • property-list 1

    Property list (plist) library with all formats support

  • keycap 1

    1.5u keycap for Kailh low profile switch

  • ffi-clang 0

    Ruby FFI bindings for libclang 3.4+.

  • llvm-node 0

    Node LLVM 4.0+ Bindings

More on GitHub
  • 概况
  • 话题
  • 回帖
  • 收藏
  • 正在关注
  • 关注者
  • 用 ubuntu 的朋友试过 “终端” 无法显示中文和无法输入中文的问题吗? at 2013年02月06日

    要用正确的 readline 版本 (例如 rvm 装的)

  • 关于 Marshal.dump 失败 no _dump_data is defined for class Proc at 2013年02月06日

    应该是有个属性包含了 Proc 对象,可以逐一迭代看看是哪个属性:

    ...
    p.save
    p.instance_variables.each do |v|
      content = p.instance_variable_get v
      puts "dumping @#{v} = #{content.inspect}"
      Marshal.dump v
    end
    

    dump 之前把有问题的属性设成 nil 就可以了

  • 刚发了个 gem: triez (加了个全文搜索服务器的例子) at 2013年02月05日

    #27 楼 @googya 是的,名字不太好,1.0 改了-_- Triez.new value_type: :object

  • 刚发了个 gem: triez (加了个全文搜索服务器的例子) at 2013年02月05日

    #25 楼 @i5ting 我只是利用了大神的成果而已... 翻译如下:

    简介:trie 这个主意看起来很简单,但是指针吃了很多内存,burst trie 做得不错,说不定能和几年前发的 array hash 结合起来 背景:列了很多年份 HAT-trie: 主意就是把 burst trie 的二叉搜索树替换成 array hash 的 bucket, 看那张图就可以了... 设计:搞了两个版本,pure 版压缩性一般,hybrid 版不错 性能评测:另外由于链表版二叉搜索树是内存杀手,还专门写了压缩版的二叉搜索树来说明它不能行

  • 刚发了个 gem: triez (加了个全文搜索服务器的例子) at 2013年02月05日

    #22 楼 @ywjno thanks, 已修正

  • 刚发了个 gem: triez (加了个全文搜索服务器的例子) at 2013年02月04日

    #16 楼 @fsword 好生奇怪... 一般这种问题是只有 RHEL 才有才对... 已 fix, 现在 0.3 了 @keating 同样是 ubuntu... @ywjno xp 威武

  • 刚发了个 gem: triez (加了个全文搜索服务器的例子) at 2013年02月04日

    #13 楼 @Saito 这是个 suffix trie, 插入 'ACACD' 话相当于在正常 trie 里插入 'ACACD', 'CACD', 'ACD', 'CD', 'D' 这 5 项 (参考 readme 里万塘路一锅鸡的例子), 所以前缀搜索就能实现全文搜索的效果...

    P.S. 是 triez 不是 tries 啊...

  • 刚发了个 gem: triez (加了个全文搜索服务器的例子) at 2013年02月04日

    @Saito fixed, version=0.2 了

  • 刚发了个 gem: triez (加了个全文搜索服务器的例子) at 2013年02月04日

    那个 pstdint.h 是 hat-trie 带的,文件上头注释里写了这么长说这个是为了强大的可移植性,结果开门就引了个 windows 绝对没有的 signal.h 囧死...

  • 刚发了个 gem: triez (加了个全文搜索服务器的例子) at 2013年02月04日

    #5 楼 @Saito very helpful! 回帖的模范!

  • 刚发了个 gem: triez (加了个全文搜索服务器的例子) at 2013年02月04日

    @hooopo @whitecrow @fleuria 其实发出来是想看有没有各种编译不了或者 segfault 的...

  • RVM 安装 Ruby 2.0.0 的 OpenSSL 问题 at 2013年02月04日

    @ranmocy 从日志里看出 openssl configure 出错的直接原因应该就是你在命令行指定的 --with-openssl-dir 参数传递到了 openssl configure 那一步里... 难道是 reinstall 不支持 install 的参数...?

  • RVM 安装 Ruby 2.0.0 的 OpenSSL 问题 at 2013年02月04日

    @ranmocy 好吧那个 make 报 inline asm 错误归根原因是 openssl configure 就出错了,真正原因在 /Users/ranmocy/.rvm/log/ruby-2.0.0-rc1/openssl/configure.log 里

  • Mac 下为何这么吃内存 at 2013年02月04日

    用 activity monitor 看内存... chrome renderer 是内存杀手

  • RVM 安装 Ruby 2.0.0 的 OpenSSL 问题 at 2013年02月04日

    @ranmocy 看了一下你的 gist, 错误信息是不支持 inline asm, 但是 rvm 是用 no-asm 去配置 openssl 的应该不会碰到,而且我修改 rvm 开启 asm 安装 openssl 也没出现问题...

    如果换了编译器,把 ~/.rvm/src/ruby-2.0.0-rc1 删掉再 reinstall

  • RVM 安装 Ruby 2.0.0 的 OpenSSL 问题 at 2013年02月04日

    #3 楼 @ywjno 不用 apple-gcc42, export CC=clang 即可

  • 如何解决 stack level too deep (SystemStackError) 的问题 at 2013年02月03日

    simple fix:

    def FindUnassignedLocation(grid)
       0.upto(N-1) do |x|
        0.upto(N-1) do |y|
          if grid[x][y] == UNASSIGNED then return x,y end
        end
      end
      return false
    end
    
    ...
    
    def SolveSudoku(grid)
      row, col = FindUnassignedLocation(grid)
      return true unless row
    
    ...
    
  • 如何解决 stack level too deep (SystemStackError) 的问题 at 2013年02月03日
    row, col = 0, 0
    

    一直都在 0, 0 跑不下去,死循环了

  • rails 的确不是虚拟主机玩的, 我的 vps 内存耗尽死机了! at 2013年02月03日

    写日志几乎没内存影响的...

    最好检查一下报警的时候 nginx 的请求日志和对应的机器状态,说不定能找到代码中的问题

    你是多线程还是多进程部署? Ruby 版本是 1.9.2 以下或者比较早的 1.9.3 的话,unicorn 在 GC 后反而会吃更多内存... 最好更新到最新的 1.9.3

    另外还可以查查 mysql 的连接数

    还有个可能是提供商在你的 vps 所在的机器跑了什么吃内存的程序...

  • capistrano 之外的选择,用 mina 部署果然快 at 2013年02月02日

    awesome! 和 capistrano 讲再见了

  • 各位有没有遇到过 rails s 段错误的问题啊? at 2013年02月02日

    #4 楼 @ftiasch 有 segfault 的栈信息的话或许能知道...

  • [挖鼻] 我的第一个开源项目 [/ 挖鼻] at 2013年02月01日

    #1 楼 @sailtsao 你都知道 gcc 了还不会 gcc *.c ...

  • 有人了解 RubyEE 吗?Ruby 企业版。。 at 2013年01月31日

    REE 的 GC 参数和 cow friendly memory 的修改已经合并到 1.9 了

    JEE 关注的是忽悠

  • 发帖请注意代码的格式化 at 2013年01月31日

    代码中嵌入代码... markdown ruby def foo bar end

  • Rails 工程师的薪资水平 at 2013年01月31日

    #8 楼 @jasl 果然是从小就精通 wasd 和 hjkl 的键盘流...

  • 求 link_to "Edit", [:edit, instance] 这种写法的文档 at 2013年01月31日

    http://api.rubyonrails.org/classes/ActionDispatch/Routing/PolymorphicRoutes.html#method-i-polymorphic_url

  • SASS 编译不了带中文的 utf8 文件吗? at 2013年01月29日

    @icer @AReverie

    // 这个注释输出后就没了
    /* 这个注释输出后还在 */
    a
      color: black
    

    输出结果

    @charset "UTF-8";
    /* 这个注释输出后还在 */
    a {
      color: black; }
    

    我的环境变量里 RUBYOPT=-KU, 源文件是 UTF-8 编码的,注释带中文正常,加了 bom 也正常,Sass 3.2.5

  • 如果使用 Rails 做项目,源码能保护起来吗? at 2013年01月28日

    君子不屑抄,小人看不懂. 关键的 session key 或者密码之类的保护好就够了... 独门技术可能要处理一下

  • cap deploy_via copy 的坑 at 2013年01月28日

    FreeBSD 几乎在所有方面都强于 Linux (钓鱼), 就是用户和支持的平台不够多

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