Go-to autoinject declarations

Answered

I currently use RubyMine and like its go-to functionality that lets me command-click on a method and find where it's declared.

The codebase I'm working on uses AutoInject, in this format:

include AutoInject[method_name: 'user.determine_something']

RubyMine doesn't recognize this formatting and can't link to where the autoinjected methods are defined. Is there a way to add customization so it can follow this format to where the methods are defined? 

If this is possible, I'm unsure as where to begin - any thoughts would be appreciated. 

 

 

5 comments
Comment actions Permalink

Hello,

just to be sure, should navigation go to that string defined with `include AutoInject`?

0
Comment actions Permalink

In addition, is it about Dry? Could you please check whether the following request is related:

https://youtrack.jetbrains.com/issue/RUBY-20147

0
Comment actions Permalink

Hello Olga,

 
Thanks for the response! To your first question, yes, ideally the string would allow us to navigate to its definition with autoinject. To your second question, yes, we use dry autoinject for autoinject.
 
I am not sure if it's related to the issue you linked, though it could be - I am currently away from my work computer but will check as soon as possible
 
Thanks,
 
Edward
0
Comment actions Permalink

Apologies for the lateness of my response. Our issue is separate from the one you linked.

RubyMine can't parse the dry-auto-inject declaration so I can't click through to the source file. Here's an example:  

0
Comment actions Permalink

Hello,

would it be possible to provide a working sample project for reproduce?

0

Please sign in to leave a comment.