-
Notifications
You must be signed in to change notification settings - Fork 0
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
Robert Schindler
committed
Jul 19, 2019
0 parents
commit 4960ba8
Showing
23 changed files
with
967 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,124 @@ | ||
# Byte-compiled / optimized / DLL files | ||
__pycache__/ | ||
*.py[cod] | ||
*$py.class | ||
|
||
# C extensions | ||
*.so | ||
|
||
# Distribution / packaging | ||
.Python | ||
build/ | ||
develop-eggs/ | ||
dist/ | ||
downloads/ | ||
eggs/ | ||
.eggs/ | ||
lib/ | ||
lib64/ | ||
parts/ | ||
sdist/ | ||
var/ | ||
wheels/ | ||
pip-wheel-metadata/ | ||
share/python-wheels/ | ||
*.egg-info/ | ||
.installed.cfg | ||
*.egg | ||
MANIFEST | ||
|
||
# PyInstaller | ||
# Usually these files are written by a python script from a template | ||
# before PyInstaller builds the exe, so as to inject date/other infos into it. | ||
*.manifest | ||
*.spec | ||
|
||
# Installer logs | ||
pip-log.txt | ||
pip-delete-this-directory.txt | ||
|
||
# Unit test / coverage reports | ||
htmlcov/ | ||
.tox/ | ||
.nox/ | ||
.coverage | ||
.coverage.* | ||
.cache | ||
nosetests.xml | ||
coverage.xml | ||
*.cover | ||
.hypothesis/ | ||
.pytest_cache/ | ||
|
||
# Translations | ||
*.mo | ||
*.pot | ||
|
||
# Django stuff: | ||
*.log | ||
local_settings.py | ||
db.sqlite3 | ||
db.sqlite3-journal | ||
|
||
# Flask stuff: | ||
instance/ | ||
.webassets-cache | ||
|
||
# Scrapy stuff: | ||
.scrapy | ||
|
||
# Sphinx documentation | ||
docs/_build/ | ||
|
||
# PyBuilder | ||
target/ | ||
|
||
# Jupyter Notebook | ||
.ipynb_checkpoints | ||
|
||
# IPython | ||
profile_default/ | ||
ipython_config.py | ||
|
||
# pyenv | ||
.python-version | ||
|
||
# pipenv | ||
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. | ||
# However, in case of collaboration, if having platform-specific dependencies or dependencies | ||
# having no cross-platform support, pipenv may install dependencies that don't work, or not | ||
# install all needed dependencies. | ||
#Pipfile.lock | ||
|
||
# celery beat schedule file | ||
celerybeat-schedule | ||
|
||
# SageMath parsed files | ||
*.sage.py | ||
|
||
# Environments | ||
.env | ||
.venv | ||
env/ | ||
venv/ | ||
ENV/ | ||
env.bak/ | ||
venv.bak/ | ||
|
||
# Spyder project settings | ||
.spyderproject | ||
.spyproject | ||
|
||
# Rope project settings | ||
.ropeproject | ||
|
||
# mkdocs documentation | ||
/site | ||
|
||
# mypy | ||
.mypy_cache/ | ||
.dmypy.json | ||
dmypy.json | ||
|
||
# Pyre type checker | ||
.pyre/ |
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,14 @@ | ||
version: 2 | ||
|
||
sphinx: | ||
configuration: docs/conf.py | ||
|
||
# Optionally build your docs in additional formats such as PDF and ePub | ||
formats: all | ||
|
||
python: | ||
version: 3.7 | ||
install: | ||
- requirements: docs/requirements.txt | ||
- method: pip | ||
path: . |
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,23 @@ | ||
language: python | ||
dist: xenial | ||
|
||
cache: | ||
directories: | ||
- "$HOME/.cache/pip" | ||
|
||
python: | ||
- "3.7" | ||
|
||
install: | ||
- pip install 'tox-travis >= 0.12' | ||
|
||
script: tox | ||
|
||
jobs: | ||
include: | ||
- { env: [TOXENV=docs], stage: Docs and linting } | ||
- { env: [TOXENV=lint] } | ||
- { env: [TOXENV=tests-django20], stage: Unit tests } | ||
- { env: [TOXENV=tests-django21] } | ||
- { env: [TOXENV=tests-django22] } | ||
- { env: [TOXENV=coverage-report], stage: Test coverage } |
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,28 @@ | ||
django-flexquery | ||
================ | ||
|
||
.. image:: https://travis-ci.org/efficiosoft/django-flexquery.svg?branch=master | ||
:alt: Build Status | ||
:target: https://travis-ci.org/efficiosoft/django-flexquery | ||
.. image:: https://coveralls.io/repos/github/efficiosoft/django-flexquery/badge.svg?branch=master | ||
:alt: Test Coverage | ||
:target: https://coveralls.io/github/efficiosoft/django-flexquery?branch=master | ||
.. image:: https://readthedocs.org/projects/django-flexquery/badge/?version=latest | ||
:alt: Documentation | ||
:target: https://django-flexquery.readthedocs.io/en/latest/ | ||
|
||
This library aims to provide a new way of declaring reusable QuerySet filtering | ||
logic in your Django project, incorporating the DRY principle and maximizing user | ||
experience and performance by allowing you to decide between sub-queries and JOINs. | ||
|
||
Its strengths are, among others: | ||
|
||
* Easy to learn in minutes | ||
* Cleanly integrates with Django's ORM | ||
* Small code footprint, less bugs - ~150 lines of code (LoC) | ||
* 100% test coverage | ||
* Fully documented code, formatted using the excellent `Black Code Formatter | ||
<https://github.com/python/black>`_. | ||
|
||
See the `documentation at Read The Docs <https://django-flexquery.readthedocs.org>`_ | ||
to convince yourself. |
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,15 @@ | ||
""" | ||
Reusable QuerySet filtering logic for Django. | ||
""" | ||
|
||
try: | ||
from .flexquery import Manager, FlexQuery, QuerySet | ||
from .q import Q | ||
except ImportError: # pragma: no cover | ||
# Django is missing, just provide version | ||
__all__ = [] | ||
else: | ||
__all__ = ["FlexQuery", "Manager", "Q", "QuerySet"] | ||
|
||
|
||
__version__ = "1.0.0" |
Oops, something went wrong.