-
Notifications
You must be signed in to change notification settings - Fork 77
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
222 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,7 @@ | ||
{ | ||
"exclude": [ | ||
"*/.tox/*" | ||
], | ||
"groups": [ | ||
{ | ||
"type": "stdlib" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
language: python | ||
|
||
python: | ||
- "3.4" | ||
- "2.7" | ||
- "pypy" | ||
- "pypy3" | ||
|
||
env: | ||
- "$DJANGO='django<1.9'" | ||
|
||
sudo: false | ||
|
||
# command to install dependencies, e.g. pip install -r requirements.txt --use-mirrors | ||
install: | ||
- pip install $DJANGO | ||
- pip install -r requirements-dev.txt | ||
- pip install coveralls | ||
- pip freeze | ||
|
||
# command to run tests, e.g. python setup.py test | ||
script: make check | ||
|
||
after_success: coveralls |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
Credits | ||
------- | ||
|
||
Development Lead | ||
---------------- | ||
|
||
* Miroslav Shubernetskiy - https://github.com/miki725 | ||
|
||
Contributors | ||
------------ | ||
|
||
None yet. Why not be the first? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
.. :changelog: | ||
History | ||
------- | ||
|
||
0.1.0 (2015-08-30) | ||
~~~~~~~~~~~~~~~~~~ | ||
|
||
* First release on PyPI. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
License | ||
------- | ||
|
||
:: | ||
|
||
The MIT License (MIT) | ||
|
||
Copyright (c) 2015, Miroslav Shubernetskiy | ||
|
||
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. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
include *.rst *.txt | ||
recursive-include tests * | ||
recursive-include docs *.rst conf.py Makefile make.bat | ||
recursive-exclude * __pycache__ | ||
recursive-exclude * *.py[co] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
.PHONY: clean-pyc clean-build docs clean | ||
|
||
help: | ||
@echo "install - install all requirements including for testing" | ||
@echo "install-quite - same as install but pipes all output to /dev/null" | ||
@echo "clean - remove all artifacts" | ||
@echo "clean-build - remove build artifacts" | ||
@echo "clean-pyc - remove Python file artifacts" | ||
@echo "clean-test - remove test and coverage artifacts" | ||
@echo "clean-test-all - remove all test-related artifacts including tox" | ||
@echo "lint - check style with flake8" | ||
@echo "test - run tests quickly with the default Python" | ||
@echo "test-coverage - run tests with coverage report" | ||
@echo "test-all - run tests on every Python version with tox" | ||
@echo "check - run all necessary steps to check validity of project" | ||
@echo "release - package and upload a release" | ||
@echo "dist - package" | ||
|
||
install: | ||
pip install -U -r requirements-dev.txt | ||
|
||
install-quite: | ||
pip install -r requirements-dev.txt > /dev/null | ||
|
||
clean: clean-build clean-pyc | ||
|
||
clean-build: | ||
@rm -rf build/ | ||
@rm -rf dist/ | ||
@rm -rf *.egg-info | ||
|
||
clean-pyc: | ||
-@find . -name '*.pyc' -follow -print0 | xargs -0 rm -f | ||
-@find . -name '*.pyo' -follow -print0 | xargs -0 rm -f | ||
-@find . -name '__pycache__' -type d -follow -print0 | xargs -0 rm -rf | ||
|
||
clean-test: | ||
rm -rf .coverage coverage* | ||
rm -rf htmlcov/ | ||
|
||
clean-test-all: clean-test | ||
rm -rf .tox/ | ||
|
||
lint: | ||
flake8 . | ||
|
||
test: | ||
py.test -sv --cov=url_filter --cov-report=term-missing tests/ | ||
|
||
test-all: | ||
tox | ||
|
||
check: lint clean-build clean-pyc clean-test test | ||
|
||
release: clean | ||
python setup.py sdist upload | ||
|
||
dist: clean | ||
python setup.py sdist | ||
ls -l dist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
-r requirements.txt | ||
Sphinx | ||
Werkzeug | ||
coverage | ||
django-extensions | ||
djangorestframework | ||
flake8 | ||
importanize | ||
ipython | ||
mock | ||
pytest | ||
pytest-cov | ||
pytest-django | ||
Sphinx | ||
sphinx-autobuild | ||
sphinx-rtd-theme | ||
tox | ||
watchdog | ||
Werkzeug |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
#!/usr/bin/env python | ||
# -*- coding: utf-8 -*- | ||
from __future__ import print_function | ||
import os | ||
|
||
from setuptools import setup | ||
|
||
from url_filter import __author__, __version__ | ||
|
||
|
||
def read(fname): | ||
return (open(os.path.join(os.path.dirname(__file__), fname), 'rb') | ||
.read().decode('utf-8')) | ||
|
||
|
||
authors = read('AUTHORS.rst') | ||
history = read('HISTORY.rst').replace('.. :changelog:', '') | ||
licence = read('LICENSE.rst') | ||
readme = read('README.rst') | ||
|
||
requirements = read('requirements.txt').splitlines() + [ | ||
'setuptools', | ||
] | ||
|
||
test_requirements = ( | ||
read('requirements.txt').splitlines() | ||
+ read('requirements-dev.txt').splitlines()[1:] | ||
) | ||
|
||
setup( | ||
name='django-url-filter', | ||
version=__version__, | ||
author=__author__, | ||
description='Django URL Filter provides a safe way to filter data via human-friendly URLs.', | ||
long_description='\n\n'.join([readme, history, authors, licence]), | ||
url='https://github.com/miki725/django-url-filter', | ||
license='MIT', | ||
packages=['url_filter'], | ||
install_requires=requirements, | ||
test_suite='tests', | ||
tests_require=test_requirements, | ||
keywords=' '.join([ | ||
'django django-rest-framework', | ||
]), | ||
classifiers=[ | ||
'Intended Audience :: Developers', | ||
'Natural Language :: English', | ||
'License :: OSI Approved :: MIT License', | ||
'Programming Language :: Python', | ||
'Programming Language :: Python :: 2.7', | ||
'Programming Language :: Python :: 3', | ||
'Programming Language :: Python :: 3.4', | ||
'Development Status :: 2 - Pre-Alpha', | ||
], | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
[tox] | ||
envlist = | ||
{py27,py34,pypy,pypy3}-django{18} | ||
|
||
[testenv] | ||
basepython = | ||
py27: python2.7 | ||
py34: python3.4 | ||
pypy: pypy | ||
pypy3: pypy3 | ||
setenv = | ||
PYTHONPATH = {toxinidir} | ||
commands = | ||
make install-quite | ||
pip freeze | ||
make check | ||
deps = | ||
django16: django<1.7 | ||
django17: django<1.8 | ||
django18: django<1.9 | ||
whitelist_externals = | ||
make | ||
|
||
[flake8] | ||
ignore = E501 |