merge branch 'f/hashbang-doc'

This commit is contained in:
Zack M. Davis 2015-12-09 21:48:38 -08:00
commit a1cb5e33e7
2 changed files with 16 additions and 4 deletions

View File

@ -31,13 +31,18 @@ Quickstart
7. Open up an elite programming editor and type::
#! /usr/bin/env hy
(print "I was going to code in Python syntax, but then I got Hy.")
8. Save as ``awesome.hy``.
9. And run your first Hy program::
9. Make it executable::
hy awesome.hy
chmod +x awesome.hy
10. Take a deep breath so as to not hyperventilate.
11. Smile villainously and sneak off to your hydeaway and do
10. And run your first Hy program::
./awesome.hy
11. Take a deep breath so as to not hyperventilate.
12. Smile villainously and sneak off to your hydeaway and do
unspeakable things.

View File

@ -306,6 +306,13 @@ Comments start with semicolons:
; (print "but this will not")
(+ 1 2 3) ; we'll execute the addition, but not this comment!
Hashbang (``#!``) syntax is supported:
.. code-block:: clj
#! /usr/bin/env hy
(print "Make me executable, and run me!")
Looping is not hard but has a kind of special structure. In Python,
we might do::