Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Moving to astor.codegen

  • Loading branch information...
commit 10b887bbc805a38298dcdea1ac469d2d197a4bac 1 parent cdffc9d
@paultag authored
View
4 bin/hy2py
@@ -2,7 +2,7 @@
from hy.importer import (import_file_to_ast, import_file_to_module,
import_file_to_hst)
-import codegen
+import astor.codegen
import sys
import ast
@@ -17,6 +17,6 @@ print ""
print ast.dump(_ast)
print ""
print ""
-print codegen.to_source(_ast)
+print astor.codegen.to_source(_ast)
import_file_to_module("<STDIN>", sys.argv[1])
View
2  requirements-dev.txt
@@ -1,5 +1,5 @@
tox
nose
+astor
flake8
-codegen
coverage
View
2  requirements-site.txt
@@ -1,4 +1,4 @@
flask
+astor
pygments
-codegen
autopep8
View
5 site/app.hy
@@ -11,7 +11,7 @@
(import-from hy.importer import_string_to_ast)
(import autopep8)
-(import codegen)
+(import astor.codegen)
(def app (Flask "__main__")) ; long story, needed hack
@@ -19,7 +19,8 @@
(defn hy-to-py [hython]
- (.fix-string autopep8 (.to_source codegen (import-string-to-ast hython))))
+ (.fix-string autopep8
+ (.to_source astor.codegen (import-string-to-ast hython))))
(defn err [msg] (make-response msg 500))
Please sign in to comment.
Something went wrong with that request. Please try again.