Parsely / schemato

Modularly extensible semantic metadata validator
http://schema.to
Apache License 2.0
83 stars 9 forks source link

Add a setup.py, and publish to PyPI #2

Closed nvie closed 12 years ago

nvie commented 12 years ago

That way, people can start using it by a simple pip install mrschemato.

emmettbutler commented 12 years ago

this would require a separation between the server and the module, right? the repo right now contains a tornado/flask server that serves the web interface, and I imagine that might have to be removed if this is going to be put on PyPI

nvie commented 12 years ago

You wouldn't necessarily need to separate the server from the rest. You could provide a script that you can use to run the server and have that installed with pip, provided that it runs out of the box and is configurable using cmdline arguments rather than a settings file. It has to be zero-conf after it's installed.

If you can provide such, people can simply install the library with pip to use the API, while also having the choice of using the server script that is installed along with it.

For inspiration, you might look at this section of RQ's setup.py, to see how the scripts can be installed.

Another option would be to use a __main__.py file, so people can run python -m mrschemato.