File: ipython.sh

package info (click to toggle)
ipython 0.13.1-2%2Bdeb7u1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 15,752 kB
  • sloc: python: 69,537; makefile: 355; lisp: 272; sh: 80; objc: 37
file content (12 lines) | stat: -rwxr-xr-x 369 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
#! /bin/sh

# determine desired Python version from filename
VERSION="${0##*ipython}"

if [ ! -f /usr/bin/python$VERSION ]
then
	echo "Please install the python$VERSION package." >&2
	exit 1
else
	exec python$VERSION -c "import sys; sys.argv[0] = '/usr/bin/ipython$VERSION'; from IPython.frontend.terminal.ipapp import launch_new_instance; launch_new_instance()" $@
fi