[IPython-User] Hide/disable magic commands
Mon Sep 5 15:11:02 CDT 2011
On 2 September 2011 08:27, <email@example.com> wrote:
> Is there a way to disable magic commands or at least hide them (i.e. they
> don’t show up on tab complete)?****
> ** **
> I am planning to use IPython as a command line for controlling experiments
> and do not want to give the users access to the power of magic commands as
> it would only result in trouble!
I don't know of anything official, but I think it should be possible to
disable them altogether:
ip = get_ipython()
Note that this may not be future-proof, because at some point magic
functions will likely be moved to a separate object.
On a broader note, do think carefully about what you're removing - some
users might find certain magic commands quite useful, e.g.%run. Keeping them
hidden from tab completion seems like a better solution, but I don't know if
there's an easy way to do that.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the IPython-User