3

Anyone else have a solution to this? IntelliJ freaks out when I use the new named arguments feature for ruby 2 in a method

def initialize(ini_url:, rundeck_url:, environment:, user:)
end

Or when calling a method supplying the named arguments

deploy_from_ini = DeployFromINI.new(ini_url: options[:ini_url],
rundeck_url: options[:rundeck_url],
environment: options[:environment],
user: options[:user])

This doesn't go away even if I set the project level SDK to ruby 2.1.4

I've upgraded to IntelliJ 14.0, upgraded to the latest ruby plugin (version 7.0.0.20141015) and still am getting red lines all over, which is highly irritating. I've considered RubyMine but I've read that the plugin can lag behind RubyMine. Not sure if this would solve the issue and then I'd be introduced to the workflow of having to flip back and forth between RubyMine and IntelliJ, since the project I'm working on isn't fully ruby, just has ruby spattered across it in various places.

3
  • Works fine for me, although for Ruby 2.1.1. Nov 6, 2014 at 18:55
  • In case you use Intellij IDEA (the last one 143.870) there was an issue for Ruby plugin: youtrack.jetbrains.com/issue/RUBY-17327, which is fixed for the latest plugin version If you use RubyMIne (the last version is 8.0.1) please check the language level for your Ruby SDK in Preferences
    – Olivia
    Nov 24, 2015 at 16:53
  • I confirm, named arguments don't work in RubyMine 6.0.4
    – yegor256
    Dec 10, 2016 at 10:29

1 Answer 1

2

This isn't the answer you want but yes, RubyMine does understand named parameters (including the "required param" bare-colon syntax you showed above).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.