Skip to content

Instantly share code, notes, and snippets.

@rybesh
Forked from jacobian/ipy_user_conf.py
Created November 17, 2009 17:54
Show Gist options
  • Save rybesh/237100 to your computer and use it in GitHub Desktop.
Save rybesh/237100 to your computer and use it in GitHub Desktop.
IPython user config
import os
import sys
import StringIO
import ipy_defaults
import ipy_stock_completers
import IPython.ipapi
ip = IPython.ipapi.get()
o = ip.options
o.autocall = False
o.autoedit_syntax = True
o.autoindent = True
o.automagic = True
o.banner = False
o.confirm_exit = False
o.messages = False
# Make the prompt a bit more like the standard shell.
o.prompt_in1 = '[\#] >>> '
o.prompt_in2 = ' .\D.: '
o.prompt_out = '[\#] : '
o.separate_out = ''
o.separate_out2 = ''
# Load project-specific init file (imports, setup, etc).
ip.ex("execfile('init.py')")
# Turn on logging but don't show the stupid banner.
stdout = sys.stdout
buffer = StringIO.StringIO()
sys.stdout = buffer
ip.magic("logstart ipython.log append")
sys.stdout = stdout
buffer.close()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment