         (if type == 'stdout' then out else err) data
       delete obj.events
 
+  boot: (ipc) -> ipc.rpc 'ping'
+  console: (ipc) -> ipc.rpc 'evalrepl', {code: 'Void()'}
+  editor: (ipc) -> ipc.rpc 'eval', {text: '2+2', mod: 'Main', line: 1, path: 'untitled'}
+  completions: (ipc) -> ipc.rpc 'cacheCompletions', 'Main'
+
+  warmup: (obj) ->
+    obj.init = Promise.resolve()
+    obj.proc.socket
+      .then (sock) =>
+        return unless obj.cached
+        ipc = new IPC sock
+        [@boot, @console, @editor, @completions].forEach (f) ->
+          obj.init = obj.init.then ->
+            if obj.cached then f ipc
+        obj.init = obj.init
+          .catch (err) -> console.warn 'julia warmup error:', err
+          .then -> ipc.unreadStream()
+        return
+      .catch ->
+
   get: (path, args) ->
     @start path, args
-    if (proc = @fromCache path, args)
-      Promise.resolve proc
-    else
-      basic.get path, args
+    if (proc = @fromCache path, args) then proc
+    else basic.get path, args

    @procs[key] = @procs[key].filter (x) -> x != obj

  toCache: (path, args, proc) ->
    @cache(path, args).push proc

  fromCache: (path, args) ->
    ps = @cache path, args
    p = ps.shift()
    if p == @booting then delete @booting
    @start path, args
    p?.proc

  start: (path, args) ->
    if @booting

{isEqual} = require 'underscore-plus'
{hook} = require '../../misc'
basic = require './basic'

IPC = require '../ipc'

module.exports =

