RubyMine extension for Rio can not work!
I have write an extension for Rio, code as following:
[code]
def register_rio_types()
describe 'Kernel' do
set_return_type "rio" => "RIO::Rio"
end
describe 'RIO::Rio' do
set_return_type "files" => "RIO::Rio"
end
end
register_rio_types
[code]
The code completion can work for rio("oooo").files("pppp").<caret>, please take a look the attachment. I made a mistake?
Attachment(s):
rio.png
请先登录再写评论。
Another question is about block variable, and I have following code:
rio('public/statics/images/chiling').each do |f|
f.<caret>
end
Can I write extensions to make code completion for 'f' variable? Thanks.
Sorry, I make a mistake, the correct code as following:
describe "RIO::IF::GrandeEntry" do
set_return_type "files" => "RIO::Rio"
end
But question is how to implement code completion for block variable.
Hello,
Should be
Thus whole extension is:
By some reason in this "set_block_variable_type" doesn't work in my RubyMine 2.0 I will investigate it later to day.
Thanks. I have issued this problem to YouTrack. http://youtrack.jetbrains.net/issue/RUBY-5570
Fix will be available in 2.0.1 update
It can not work for me with following code in 2.0.1, and can you make it work? Screenshot will be great
rio("d:").each do |file|
puts file.<caret>
end
I can not get "filename" in the popup menu.
Screenshot =)

But unfortunately you are right I also cannot make it working, although it worked in past. By I a mistake this cucumber test was removed from our build configuration and probably somebody broke my fix. I've reopened the issue.
Fix will be available in coming RubyMine 2.0.2 update