Workflow for quick running of an executable in a Gem I'm writing
I've followed the tutorial videos for writing a Rubygem in RubyMine (e.g. http://blog.jetbrains.com/ruby/2013/06/gem-development-with-rubymine) and it works fine. What I'm less clear on is how to set things up so that I can quickly run my gem after code edits without doing 'Install gem' and then running IRB console.
My gem has an executable, so what I'm looking for is a single IDE action that compiles, installs the gem and then runs my gem exectuable (from the bin/ folder). Can this be done?
Thanks!
Please sign in to leave a comment.
Ah, think I've found it:
I've added a 'Run gem' configuration for my gem, and added a 'before launch' task of 'rake install'. This is the correct way I assume!
Cheers.
It is the correct way the only quation is why do you need this? :)
Regards, Oleg.
Hi Oleg, thanks. I'm not sure why you ask "why do you need this?", is there a better way or a different thing I should be doing?
Thanks.
Hi,
I meant: why do you need to do this action often? Why do you want to run your gem often during its development?
Regards, Oleg.
That's exactly what I want to do - run the gem often during its development. I'm quite new to Ruby so maybe I'm missing something obvious.
What's the easiest way to run the gem during development?
Are you testing gem manually? Perhaps tests would be better solution ;)
Oleg.