'运行跳转到方法定义失败'错误:TextMate:Module的未定义方法`current_line'

Bad*_*est 9 ruby textmate

更新:我明白了.Ctrl-F仅在未选择我正在搜索的方法时有效.游标只需要是方法名称.

我刚升级到TextMate2.

当我选择一个方法并使用Ctrl+ F来定义它时,我得到:

> Failure running Jump to Method Definition
Run Code Online (Sandbox Code Playgroud)

这是跟踪:

/Users/ilikepie/Library/Application Support/TextMate/Managed/Bundles/Ruby on Rails.tmbundle/Support/lib/rails/text_mate.rb:54:in `method_missing': undefined method `current_line' for TextMate:Module (NoMethodError)
    from /Users/ilikepie/Library/Application Support/TextMate/Managed/Bundles/Ruby on Rails.tmbundle/Support/bin/jump_to_method_definition.rb:13:in `initialize'
    from /Users/ilikepie/Library/Application Support/TextMate/Managed/Bundles/Ruby on Rails.tmbundle/Support/bin/jump_to_method_definition.rb:147:in `new'
    from /Users/ilikepie/Library/Application Support/TextMate/Managed/Bundles/Ruby on Rails.tmbundle/Support/bin/jump_to_method_definition.rb:147
Run Code Online (Sandbox Code Playgroud)

我也可以选择编辑命令".这是"跳转到方法"定义的代码:

#!/usr/bin/env bash
[[ -f "${TM_SUPPORT_PATH}/lib/bash_init.sh" ]] && . "${TM_SUPPORT_PATH}/lib/bash_init.sh"

RUBYLIB="$TM_BUNDLE_SUPPORT/lib:$RUBYLIB"
"${TM_RUBY:=ruby}" -- "${TM_BUNDLE_SUPPORT}/bin/jump_to_method_definition.rb"
Run Code Online (Sandbox Code Playgroud)

我错过了一个环境变量吗?

Bad*_*est 0

我想到了。仅当未选择我正在搜索的方法时,Ctrl-F 才有效。光标只需位于方法名称中。