H...">

Has anyone tried using IPython with Hylang syntax?

You can use Hylang with this magic:

In [1]: %%script hy (print "Hello, Cuddlefish!") ...: => Hello, Cuddlefish! => hy 0.9.12 In [2]: 

I want to use it directly:

 In [1]: (print "Hello, Cuddlefish!") Hello, Cuddlefish! Int [2]: 
+7
python ipython
source share
2 answers

Try my hymagic module. You can install it with

 $ pip install hymagic 

Download magic using

 %load_ext hymagic 

Use %hylang for one row and %%hylang for the whole cell. for example

 %hylang (+ 1 2 3) 

and

 %%hylang (defn hello [] (print "hello world")) (hello) 
+4
source share

Instead, you can install hy kernel , where there is no need for a prefix

% hylang

at the beginning of each cell.

+2
source share

All Articles