[IPython-dev] Cell Magic names

Min RK benjaminrk at gmail.com
Sat Jun 2 20:54:19 EDT 2012


I don't like lang, because it doesn't actually communicate what it does. For instance you could use it to select one of the half-dozen Pythons or venv-pythons, etc.

I agree that shebang is unclear to users who don't know what it means (and
is this probably a poor choice, but still my personal favorite, because I think it's fun), but it most accurately describes what the magic does (to the minority aware of the reference): run the rest of the cell with the *program* described on this line.

I think script is probably best, and should then have a default interpreter of 'sh' (or $SHELL?).

-MinRK

On Jun 2, 2012, at 12:30, Carl Smith <carl.input at gmail.com> wrote:

> If the magic knows the installed interpreters and what not, couldn't you just do...
> 
> %%lang bash
> echo hello world
> 
> On Jun 2, 2012 8:24 PM, "Fernando Perez" <fperez.net at gmail.com> wrote:
> >
> > On Sat, Jun 2, 2012 at 10:46 AM, Carl Smith <carl.input at gmail.com> wrote:
> > > Just a thought: How about calling it lang?
> >
> > lang or script both sound OK to me, and indeed I prefer them to
> > shebang, I concur with Thomas on this one.
> >
> > Cheers,
> >
> > f
> > _______________________________________________
> > IPython-dev mailing list
> > IPython-dev at scipy.org
> > http://mail.scipy.org/mailman/listinfo/ipython-dev
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> http://mail.scipy.org/mailman/listinfo/ipython-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20120602/19f349cc/attachment.html>


More information about the IPython-dev mailing list