Skip to content

Instantly share code, notes, and snippets.

@juliantaylor
juliantaylor / ipython_bashcomp
Created August 22, 2012 18:05
ipython bash completions WIP
_ipython_get_flags()
{
local url=$1
local var=$2
local dash=$3
if [[ "$url $var" == $__ipython_complete_last ]]; then
opts=$__ipython_complete_last_res
return
fi
opts=$(cat <<EOF | python -
@juliantaylor
juliantaylor / gist:1456031
Created December 10, 2011 19:24
use system mathjax
diff --git a/IPython/frontend/html/notebook/notebookapp.py b/IPython/frontend/html/notebook/notebookapp.py
index e7a00c0..7b60934 100644
--- a/IPython/frontend/html/notebook/notebookapp.py
+++ b/IPython/frontend/html/notebook/notebookapp.py
@@ -105,6 +105,11 @@ class NotebookWebApplication(web.Application):
(r"/notebooks/%s" % _notebook_id_regex, NotebookHandler),
(r"/rstservice/render", RSTHandler)
]
+
+ if os.path.exists("/usr/share/javascript/mathjax/MathJax.js"):
@juliantaylor
juliantaylor / gist:1456004
Created December 10, 2011 19:18
use system mathjax
diff --git a/IPython/frontend/html/notebook/notebookapp.py b/IPython/frontend/html/notebook/notebookapp.py
index e7a00c0..217fe7e 100644
--- a/IPython/frontend/html/notebook/notebookapp.py
+++ b/IPython/frontend/html/notebook/notebookapp.py
@@ -103,7 +103,8 @@ class NotebookWebApplication(web.Application):
(r"/kernels/%s/shell" % _kernel_id_regex, ShellHandler),
(r"/notebooks", NotebookRootHandler),
(r"/notebooks/%s" % _notebook_id_regex, NotebookHandler),
- (r"/rstservice/render", RSTHandler)
+ (r"/rstservice/render", RSTHandler),
@juliantaylor
juliantaylor / console.py.20110802.diff
Created August 5, 2011 15:28 — forked from ogra/console.py.20110802.diff
Scrapy 0.12.0.2543 scrapy/utils/console.py patch for IPython 0.11
--- console.py.orig 2011-07-31 08:01:34.000000000 +0000
+++ console.py 2011-08-02 20:38:56.000000000 +0000
@@ -11,7 +11,10 @@
if noipython:
raise ImportError
import IPython
- shell = IPython.Shell.IPShellEmbed(argv=[], user_ns=namespace)
+ if IPython.__version__ == '0.11':
+ IPython.embed(user_ns=namespace)
+ else:
@juliantaylor
juliantaylor / ipython_view.py
Created July 23, 2011 13:28
exaile ipy fix
"""
Backend to the console plugin.
@author: Eitan Isaacson
@organization: IBM Corporation
@copyright: Copyright (c) 2007 IBM Corporation
@license: BSD
All rights reserved. This program and the accompanying materials are made
available under the terms of the BSD which accompanies this distribution, and
@juliantaylor
juliantaylor / mail
Created July 21, 2011 16:25
ipython rdeps
# grep-dctrl -F Suggests -F Depends -F Build-Depends -F Build-Depends-Indep ipython -s Source:Package /var/lib/apt/lists
/*_{Sources,Packages} | sed -e "s/Package: //" | sort -u
accerciser
connectomeviewer
dipy
griffith
matplotlib
mayavi2
parti-all
polybori
the extra free line after description is unnecessary
- I'm not sure what you mean. which line, exactly?
Description: Asynchronous Messaging Protocol library for .NET.
. <<<<<<<<<<<<<<<<< this one
AMP is an RPC protocol for sending multiple asynchronous request/response
add a watchfile debian/watch, content:
version=3
https://launchpad.net/ampsharp/+download .*/AMPSharp-src-([\d.]+).zip
upstream:
please add copyright headers to the source files
installation error:
! Assembly /usr/share/cli-common/policies.d/libampsharp2.0-cil/policy.2.0.AMPSharp.dll does not exist
debian/format:
should be debian/source/format
debian/control: