Commit Graph

69 Commits

Author SHA1 Message Date
Kodi Arfer
21f13b977d Update NEWS and classifiers for Python 3.7 support 2018-03-24 12:39:54 -07:00
Kodi Arfer
f27eda16e1 Depend on an unstable version of astor
We need it for Python 3.7.
2018-03-24 12:34:43 -07:00
Kodi Arfer
6de7ddfee5 Update copyright years 2018-01-01 10:38:33 -05:00
gilch
6bb997dbea update astor to 0.6 2017-10-31 14:13:41 -06:00
Kodi Arfer
0fc96306bc Drop support for Python 3.3 2017-08-26 13:36:51 -07:00
Ryan Gonzalez
292f445a0a Update rply to 0.7.5
Closes #1313. Ref. alex/rply#52, alex/rply#71.
2017-07-12 15:53:07 -05:00
Kodi Arfer
7361b37a75 Add get_version as a data file to setup.py 2017-06-15 11:30:05 -07:00
Kodi Arfer
032830bada Mark support for Python 3.6 in setup.py 2017-06-15 11:11:54 -07:00
Kodi Arfer
dd9774fb6d Remove the documentation's dependency on Hy itself 2017-05-23 11:28:28 -07:00
gilch
b9279183d7 Merge pull request #1286 from Kodiologist/new-license-headers
Use license headers consistently
2017-05-22 13:36:53 -06:00
Kodi Arfer
a537d33471 In setup.py, handle backslash-separated paths (#1284)
The obvious way to do this is to apply os.path.split iteratively, and I tried that first, but it seemed like overkill for setup.py.
2017-05-03 18:47:52 -05:00
Kodi Arfer
2eb81864df Make all files comply with license-header policy 2017-04-27 14:16:57 -07:00
Kodi Arfer
ef3bad7e03 Drop support for Python 2.6 2017-04-24 14:18:56 -07:00
Kodi Arfer
a9cfe25068 Sort the results of os.walk in setup.py (#1281)
os.walk need not provide its results in any specific order. So, sorting might help with situations like that described in #1280. Even if not, it could help avoid some very mysterious bugs in the future that arise from different orders in which Hy's modules are imported.
2017-04-24 09:54:15 -05:00
Kodi Arfer
2b11b9be20 Automatically read and write bytecode
Importing or executing a Hy file now loads the byte-compiled version if it exists and is up to date, and if not, the source is byte-compiled after it's parsed.

This change can speed up Hy a lot. Here are some examples comparing run times of the current master (491b474e) to this commit, on my laptop with Python 3.6:

- `nosetests --exclude='test_bin'` goes from 3.8 s to 0.7 s (a 5-fold speedup)
- `hy -c '(print "hello world")` goes from 0.47 s to 0.20 s (a 2-fold speedup)
- Rogue TV's startup goes from 3.6 s to 0.4 s (a 9-fold speedup)

Accompanying changes include:

- `setup.py` now creates and installs bytecode for `hy.core`, `hy.contrib`, and `hy.extra`.
- The `hyc` command under Python 3 now creates bytecode in `__pycache__`, as usual for Python 3, instead of putting the `.pyc` right next to the source file like Python 2 does.

I've removed a test of `hy.extra.anaphoric.a-if` that triggers #1268 when the test file is byte-compiled and then hits some weird `macroexpand` bug or something when I try to work around that—Nose crashes when trying to produce an error message, and I can't seem to replicate the bug without Nose.
2017-04-14 13:38:33 -07:00
Kodi Arfer
fe0fb6fba1 Use try instead of if in setup.py 2017-01-24 08:31:38 -08:00
Kodi Arfer
6e7e94dd8e Tweak __version__ handling in setup.py 2017-01-20 13:34:15 -08:00
Tuukka Turto
fe8209bf03 Include hy.extra in packaging (#1201)
closes #1200
2017-01-17 12:46:58 -06:00
Kodi Arfer
f831b3e98f Merge branch 'entry_point' 2016-11-25 16:04:24 -08:00
Kodi Arfer
ac01c0f03f Changed version punctuation for PEP 440 compliance
They now look like:  0.11.0+295.gec6e264.dirty
instead of:          0.11.0-295-gec6e264-dirty
2016-10-13 13:41:14 -07:00
Kodi Arfer
ec6e264753 Allow calling setup.py from a subdirectory 2016-10-13 13:32:13 -07:00
Kodi Arfer
23c457cee5 Generate hy.version using git describe 2016-10-12 17:11:44 -07:00
Zack M. Davis
888c7efe0c tighten pyreadline requirement [#1011, #1022] 2016-02-01 21:51:51 -08:00
2alex2
81b2aebf9f Update setup.py
Fix Python 3.5 compatibility for Windows.
2015-12-31 16:41:34 +02:00
Felix Yan
864fa66f22 Enable automated testing with Python 3.5
and switch travis to use tox
2015-11-03 23:32:31 +08:00
Ryan Gonzalez
83540666fe Add versioned entry point scripts (closes #931) 2015-09-05 18:24:51 -05:00
Zack M. Davis
d40405fde3 bump astor dependency to 0.5 to support matrix multiplication operator
See berkerpeksag/astor@0350295e.
2015-04-19 20:24:25 -07:00
Bob Tolbert
54ce193c41 Merge pull request #702 from berkerpeksag/add-clint
Add clint as a dependency.
2014-12-07 10:58:30 -07:00
Berker Peksag
94362e903d Add clint as a dependency.
Since clint 0.3, it supports Python 3.
2014-12-06 21:15:59 +02:00
Berker Peksag
5004e754d3 Remove Python 3.2 from classifiers. 2014-12-06 21:06:11 +02:00
Berker Peksag
cdea12b276 Make hy2py public. 2014-04-30 01:51:21 +03:00
Berker Peksag
f53644568a Add Python 3.4 to classifiers. 2014-03-18 10:27:35 +02:00
Berker Peksag
870c136469 Add astor to install_requires.
`hy --spy` fails on hy 0.9.11.

    $ hy --spy
    hy 0.9.11
    => (type "hy")
    Traceback (most recent call last):
      File "/usr/local/lib/python2.7/dist-packages/hy/cmdline.py", line 68, in print_python_code
        import astor.codegen
    ImportError: No module named astor.codegen
2013-12-10 17:46:45 +02:00
Kevin Zita
8970662dcb Update requirements.txt and setup.py to use rply upstream.
Closes #364.
2013-12-08 07:11:42 +02:00
Berker Peksag
1919963eb3 Add importlib to install_requires on Python 2.6.
Fixes #319.
2013-11-10 14:55:36 +02:00
Berker Peksag
5467d2f6be Fix rply dependency.
To test this, replace the https://github.com/hylang/rply/zipball/master#egg=rply-0.6.2
url with https://github.com/berkerpeksag/rply/zipball/master#egg=rply-0.6.2
in setup.py.

$ cd hy
$ virtualenv dummy
$ . dummy/bin/activate
$ pip install .
$ pip install astor nose
$ make test
...
...
Ran 252 tests in 9.723s

OK
2013-11-04 16:12:11 +02:00
Nicolas Dandrimont
2ab35332a0 Ship the hy files in hy/contrib 2013-11-01 04:04:12 +01:00
Berker Peksag
522553ffec Various setup.py enhancements.
- PEP8 fixes
- Use setuptools.find_packages()
- Update PyPI classifiers
- Update website URL
- Install the argparse module in Python 2.6 and before
- Delete the duplicate rply in install_requires. With the PyPI
  version, tests are failed.
2013-09-20 09:08:29 +03:00
Nicolas Dandrimont
51358e0f4b Add some machinery to avoid importing hy in setup.py 2013-07-28 19:34:59 +02:00
Nicolas Dandrimont
ce22e49b50 Add rply to dependencies
Use the hylang fork until mainline grows the source position patch.
2013-07-28 17:36:36 +02:00
Bob Tolbert
df7bb1d29a Provide bin scripts for both Windows and *nix
Summary: This update does away with the scripts in bin and changes
setup.py to use entry_points in cmdline.py for the scripts 'hy' and
'hyc'.

This fixes installing and running on Windows.

The tests are updated to run the 'hy' script produced by setup.py
and not from bin/hy. This is more correct and makes the tox tests
run on both Window and *nix.

For running hy or nosetests directly in the source tree, you do have
to run 'python setup.py develop' first. But since tox runs and builds
dists, all tox tests pass on all platforms.

Also, since there is no built-in readline on Windows, the setup.py
only on Windows requires 'pyreadline' as a replacement.

Switched from optparse to argparse in cmdline.py

Instead of trying to manually separate args meant for
hy from args meant for a hy script, this switches from
optparse to argparse for the CLI.

argparse automatically peels out args meant for hy and leaves
the rest, including the user hy script in options.args.

This fixes the issue @paultag found running "hy foo" where
foo is not a real file. Also added a test that makes sure
trying to run a non-existent script exits instead of dropping
the user into the REPL.

Added argparse as setup.py resource (and removed from tox.ini) as well as removed uses of deprecated setf
2013-07-14 09:06:42 -06:00
Paul Tagliamonte
3358b5581c Include hy files in the release. 2013-07-06 19:40:47 -04:00
Ralph Moritz
888dc19882 Get Hy working on Windows by making readline use conditional. 2013-07-01 22:41:56 +02:00
Paul R. Tagliamonte
a46a9830ec Forgot these. 2013-03-27 22:19:57 -04:00
Paul Tagliamonte
980cd493e0 futzing with a few things 2013-03-21 19:27:34 -04:00
Paul R. Tagliamonte
d1ac469a3b adding in 2.6, we added it back in to the code 2013-03-17 11:55:40 -04:00
Paul R. Tagliamonte
9cdc7d0465 Adding in classifiers. 2013-03-10 17:41:35 -04:00
Paul Tagliamonte
3028570995 fail! 2013-03-08 18:47:59 -05:00
Paul R. Tagliamonte
7a925b5ee4 futzing with ideas 2013-03-05 20:28:09 -05:00
Paul Tagliamonte
4a78498133 adding numbers 2013-03-05 18:28:27 -05:00