Skip to content

How to work with prototype

Alexey Grishin edited this page Jan 8, 2014 · 2 revisions

Prepare to work

  1. Download the prototype from here
  2. Unpack pal-server-0.5.zip and run server.bat (you need java to be installed and added to PATH)
  3. Try to open http://localhost:4567/languages in browser - you shall see response like this {"ok":true,"value":["ruby","java"]}
  4. Run Idea or RubyMine and add pal plugin (idea-plugin.zip from release)

Work with prototype

  1. Create any file or class to insert code to
  2. Open 'Edit' menu - you'll find new item 'Lookup for Pal function...' Pal screenshot
  3. Click on it and type something - for example 'cap' (there are 3 functions only in this prototype :( ) Pal screenshot
  4. Select function to use and hit 'Enter'. You'll find that Pal class (module for ruby) was added to the source tree and call to the function added into the current file. Pal screenshot
  5. Write 'Pal.' and hit 'Ctrl + Space' to get code completion dialog. You'll see both already added functions and available functions from server. If you select function which is not present in the code it will be downloaded from server. Pal screenshot
  6. Take a look at the Pal class (or module, if you ran RubyMine) - it contains only functions you need and their dependencies Pal screenshot Pal screenshot

As this is just prototype then there are a lot of issues:

  • direct changes to Pal class are not processed until IDE is restarted. So if you'd like to delete Pal class then please restart IDE, otherwise plugin will think that Pal class is still on its place
Clone this wiki locally