     for cell in imported.cells
       if cell.type is 'input'
         if options.run
-          run_in_available_context cell.value
+          run_in_available_context notebook, cell.value
         else
           add_context notebook, cell.value
+    notebook
 
   clear_notebook = (notebook) ->
     notebook.$document.empty()

              @cli.object @cli[k]()
    bound_ops

  run = (input_cell, string) ->
    $el = $ '<div class="cell output"/>'

    input_cell.$el.after $el
    $top = input_cell.$el

    scroll_to_result = ($result)->

      add_input_cell notebook

    run: (cell) ->
      output_cell = cell.run()
      new_cell = add_input_cell cell.notebook, after: output_cell
      focus_cell new_cell

    handle_file: handle_file

