Andriy Kornatskyy avatar Andriy Kornatskyy committed 1e0e64a

Initial project structure.

Comments (0)

Files changed (10)

+syntax: glob                                                                   
+build/                                                                         
+dist/                                                                          
+env/                                                                           
+src/*.egg-info/                                                                
+.coverage                                                                      
+*.pyc                                                                          
+*.pyo                                                                          
+doc/_build
+Copyright (C) 2011 by Andriy Kornatskyy
+
+Permission is hereby granted, free of charge, to any person
+obtaining a copy of this software and associated documentation
+files (the "Software"), to deal in the Software without
+restriction, including without limitation the rights to use,
+copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the
+Software is furnished to do so, subject to the following
+conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.
+include LICENSE README
+.SILENT: clean env doc release test
+.PHONY: clean env doc release test
+
+VERSION=2.6
+PYPI=http://pypi.python.org/simple
+
+PYTHON=env/bin/python$(VERSION)
+EASY_INSTALL=env/bin/easy_install-$(VERSION)
+PYTEST=env/bin/py.test-$(VERSION)
+NOSE=env/bin/nosetests-$(VERSION)
+SPHINX=env/bin/sphinx-build
+
+all: clean test release
+
+debian:
+	apt-get -yq update
+	apt-get -yq dist-upgrade
+	# How to Compile Python from Source
+	# http://mindref.blogspot.com/2011/09/compile-python-from-source.html
+	apt-get -yq install libbz2-dev build-essential python \
+		python-dev python-setuptools python-virtualenv \
+		python-sphinx mercurial
+
+env:
+	PYTHON_EXE=/usr/local/bin/python$(VERSION); \
+	if [ ! -x $$PYTHON_EXE ]; then \
+		PYTHON_EXE=/usr/bin/python$(VERSION); \
+	fi;\
+	virtualenv --python=$$PYTHON_EXE \
+		--no-site-packages env
+	$(EASY_INSTALL) -i $(PYPI) -O2 -U distribute
+	$(EASY_INSTALL) -i $(PYPI) -O2 coverage nose pytest \
+		pytest-pep8 pytest-cov
+	# The following packages available for python < 3.0
+	#if [ "$$(echo $(VERSION) | sed 's/\.//')" -lt 30 ]; then \
+	#	$(EASY_INSTALL) sphinx; \
+	#fi;
+	$(PYTHON) setup.py develop -i $(PYPI)
+
+clean:
+	find src/ -type d -name __pycache__ | xargs rm -rf
+	find src/ -name '*.py[co]' -delete
+	rm -rf dist/ build/ MANIFEST src/*.egg-info
+
+release:
+	$(PYTHON) setup.py -q bdist_egg
+
+test:
+	$(PYTEST) -q -x --pep8 --doctest-modules \
+		src/wheezy/web
+
+doctest-cover:
+	$(NOSE) --stop --with-doctest --detailed-errors \
+		--with-coverage --cover-package=wheezy.web
+
+test-cover:
+	$(PYTEST) -q --cov wheezy.web \
+		--cov-report term-missing \
+		src/wheezy/web/tests
+
+doc:
+	$(SPHINX) -a -b html doc/ doc/_build/
+
+test-demos:
+	$(PYTEST) -q -x --pep8 demos/
+`wheezy.web`_ is a `python`_ package written in pure Python
+code. It provides web features.
+
+Install
+-------
+
+`wheezy.web`_ requires `python`_ version 2.4 to 2.7 or 3.2.  It
+is independent of operating system. You can install it using
+`setuptools`_::
+
+    easy_install wheezy.web
+
+
+Develop
+-------
+
+Get the `source code`_ using `mercurial`_::
+
+    hg clone https://bitbucket.org/akorn/wheezy.web
+    cd wheezy.web
+
+Prepare virtualenv environment in *env* directory and run all
+tests for python2.6 (default)::
+
+    make env test VERSION=2.6
+
+doctests can be run with python3.2::
+
+    make env doctest-cover VERSION=3.2
+
+If you run into any issue or have comments, go ahead and add on
+`bitbucket`_.
+
+User Guide and Examples
+-----------------------
+
+Please see the `user guide`_ and `examples`_ for more
+information.
+
+.. _`wheezy.web`: http://pypi.python.org/pypi/wheezy.web
+.. _`python`: http://www.python.org
+.. _`setuptools`: http://pypi.python.org/pypi/setuptools
+.. _`documented`: http://packages.python.org/wheezy.web
+.. _`examples`: https://bitbucket.org/akorn/wheezy.web/src/tip/demos/
+.. _`bitbucket`: https://bitbucket.org/akorn/wheezy.web
+.. _`source code`: https://bitbucket.org/akorn/wheezy.web/src
+.. _`mercurial`: http://mercurial.selenic.com/
+.. _`user guide`: http://packages.python.org/wheezy.web/userguide.html
+[egg_info]
+tag_build=
+tag_date=0
+tag_svn_revision=0
+
+[bdist_egg]
+exclude-source-files=True
+
+[pytest]
+#!/usr/bin/env python
+
+import os
+
+try:
+    from setuptools import setup
+except:
+    from distutils.core import setup
+
+README = open(os.path.join(os.path.dirname(__file__), 'README')).read()
+
+setup(
+    name = 'wheezy.web',
+    version = '0.1',
+    description = 'A lightweight web library',
+    long_description = README,
+    url = 'https://bitbucket.org/akorn/wheezy.web',
+
+    author = 'Andriy Kornatskyy',
+    author_email = 'andriy.kornatskyy at live.com',
+
+    license = 'MIT',
+    classifiers = [
+        'Development Status :: 4 - Beta',
+        'Intended Audience :: Developers',
+        'License :: OSI Approved :: MIT License',
+        'Natural Language :: English',
+        'Operating System :: OS Independent',
+        'Programming Language :: Python',
+        'Programming Language :: Python :: 2',
+        'Programming Language :: Python :: 2.4',
+        'Programming Language :: Python :: 2.5',
+        'Programming Language :: Python :: 2.6',
+        'Programming Language :: Python :: 2.7',
+        'Programming Language :: Python :: 3',
+        'Programming Language :: Python :: 3.2',
+        'Topic :: Software Development :: Libraries :: Python Modules',
+        'Topic :: Utilities'
+    ],
+    keywords = [
+        'web'
+    ],
+    packages = ['wheezy', 'wheezy.web'],
+    package_dir = {'': 'src'},
+    namespace_packages=['wheezy'],
+
+    zip_safe = True,
+    install_requires = [
+        'wheezy.core'
+    ],
+    extras_require = {
+        'dev': [
+            'coverage',
+            'nose',
+            'pytest',
+            'pytest-pep8',
+            'pytest-cov'
+        ]
+    },
+
+    platforms = 'any'
+)

src/wheezy/__init__.py

+# See
+# http://peak.telecommunity.com/DevCenter/setuptools#namespace-packages
+try:
+    __import__('pkg_resources').declare_namespace(__name__)
+except ImportError:
+    from pkgutil import extend_path
+    __path__ = extend_path(__path__, __name__)
Add a comment to this file

src/wheezy/web/__init__.py

Empty file added.

Add a comment to this file

src/wheezy/web/tests/__init__.py

Empty file added.

Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.