Skip to content

Commit f6f5fc9

Browse files
committed
First commit
0 parents  commit f6f5fc9

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+2663
-0
lines changed

.editorconfig

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# http://editorconfig.org
2+
3+
root = true
4+
5+
[*]
6+
charset = utf-8
7+
end_of_line = lf
8+
insert_final_newline = true
9+
trim_trailing_whitespace = true
10+
11+
[*.{py,rst,ini}]
12+
indent_style = space
13+
indent_size = 4
14+
15+
[*.{html,css,scss,json,yml}]
16+
indent_style = space
17+
indent_size = 2
18+
19+
[*.md]
20+
trim_trailing_whitespace = false
21+
22+
[Makefile]
23+
indent_style = tab

.gitignore

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
*.py[cod]
2+
__pycache__
3+
4+
# C extensions
5+
*.so
6+
7+
# Packages
8+
*.egg
9+
*.egg-info
10+
dist
11+
build
12+
eggs
13+
parts
14+
bin
15+
var
16+
sdist
17+
develop-eggs
18+
.installed.cfg
19+
lib
20+
lib64
21+
22+
# Installer logs
23+
pip-log.txt
24+
25+
# Unit test / coverage reports
26+
.coverage
27+
.tox
28+
nosetests.xml
29+
htmlcov
30+
31+
# Translations
32+
*.mo
33+
34+
# Mr Developer
35+
.mr.developer.cfg
36+
.project
37+
.pydevproject
38+
39+
# Pycharm/Intellij
40+
.idea
41+
42+
# Complexity
43+
output/*.html
44+
output/*/index.html
45+
46+
# Sphinx
47+
docs/_buildenv*

.travis.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Config file for automatic testing at travis-ci.org
2+
3+
language: python
4+
5+
python:
6+
- "3.5"
7+
- "3.4"
8+
- "3.3"
9+
- "2.7"
10+
11+
before_install:
12+
- pip install codecov
13+
14+
# command to install dependencies, e.g. pip install -r requirements.txt --use-mirrors
15+
install: pip install -r requirements_test.txt
16+
17+
# command to run tests using coverage, e.g. python setup.py test
18+
script: coverage run --source django_elasticsearch_dsl runtests.py
19+
20+
after_success:
21+
- codecov

AUTHORS.rst

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
=======
2+
Credits
3+
=======
4+
5+
Development Lead
6+
----------------
7+
8+
9+
Contributors
10+
------------
11+
12+
None yet. Why not be the first?

CONTRIBUTING.rst

Lines changed: 106 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,106 @@
1+
============
2+
Contributing
3+
============
4+
5+
Contributions are welcome, and they are greatly appreciated! Every
6+
little bit helps, and credit will always be given.
7+
8+
You can contribute in many ways:
9+
10+
Types of Contributions
11+
----------------------
12+
13+
Report Bugs
14+
~~~~~~~~~~~
15+
16+
Report bugs at https://github.com/sabricot/django-elasticsearch-dsl/issues.
17+
18+
If you are reporting a bug, please include:
19+
20+
* Your operating system name and version.
21+
* Any details about your local setup that might be helpful in troubleshooting.
22+
* Detailed steps to reproduce the bug.
23+
24+
Fix Bugs
25+
~~~~~~~~
26+
27+
Look through the GitHub issues for bugs. Anything tagged with "bug"
28+
is open to whoever wants to implement it.
29+
30+
Implement Features
31+
~~~~~~~~~~~~~~~~~~
32+
33+
Look through the GitHub issues for features. Anything tagged with "feature"
34+
is open to whoever wants to implement it.
35+
36+
Write Documentation
37+
~~~~~~~~~~~~~~~~~~~
38+
39+
Django Elasticsearch DSL could always use more documentation, whether as part of the
40+
official Django Elasticsearch DSL docs, in docstrings, or even on the web in blog posts,
41+
articles, and such.
42+
43+
Submit Feedback
44+
~~~~~~~~~~~~~~~
45+
46+
The best way to send feedback is to file an issue at https://github.com/sabricot/django-elasticsearch-dsl/issues.
47+
48+
If you are proposing a feature:
49+
50+
* Explain in detail how it would work.
51+
* Keep the scope as narrow as possible, to make it easier to implement.
52+
* Remember that this is a volunteer-driven project, and that contributions
53+
are welcome :)
54+
55+
Get Started!
56+
------------
57+
58+
Ready to contribute? Here's how to set up `django-elasticsearch-dsl` for local development.
59+
60+
1. Fork the `django-elasticsearch-dsl` repo on GitHub.
61+
2. Clone your fork locally::
62+
63+
$ git clone [email protected]:your_name_here/django-elasticsearch-dsl.git
64+
65+
3. Install your local copy into a virtualenv. Assuming you have virtualenvwrapper installed, this is how you set up your fork for local development::
66+
67+
$ mkvirtualenv django-elasticsearch-dsl
68+
$ cd django-elasticsearch-dsl/
69+
$ python setup.py develop
70+
71+
4. Create a branch for local development::
72+
73+
$ git checkout -b name-of-your-bugfix-or-feature
74+
75+
Now you can make your changes locally.
76+
77+
5. When you're done making changes, check that your changes pass flake8 and the
78+
tests, including testing other Python versions with tox::
79+
80+
$ flake8 django_elasticsearch_dsl tests
81+
$ python setup.py test
82+
$ tox
83+
84+
To get flake8 and tox, just pip install them into your virtualenv.
85+
86+
6. Commit your changes and push your branch to GitHub::
87+
88+
$ git add .
89+
$ git commit -m "Your detailed description of your changes."
90+
$ git push origin name-of-your-bugfix-or-feature
91+
92+
7. Submit a pull request through the GitHub website.
93+
94+
Pull Request Guidelines
95+
-----------------------
96+
97+
Before you submit a pull request, check that it meets these guidelines:
98+
99+
1. The pull request should include tests.
100+
2. If the pull request adds functionality, the docs should be updated. Put
101+
your new functionality into a function with a docstring, and add the
102+
feature to the list in README.rst.
103+
3. The pull request should work for Python 2.6, 2.7, and 3.3, and for PyPy. Check
104+
https://travis-ci.org/sabricot/django-elasticsearch-dsl/pull_requests
105+
and make sure that the tests pass for all supported Python versions.
106+

HISTORY.rst

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
.. :changelog:
2+
3+
History
4+
-------
5+
6+
0.1.0 (2016-22-08)
7+
++++++++++++++++++
8+
9+
* Not yet release on PyPI.

LICENSE

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
2+
Apache Software License 2.0
3+
4+
Copyright (c) 2016, Sabre
5+
6+
Licensed under the Apache License, Version 2.0 (the "License");
7+
you may not use this file except in compliance with the License.
8+
You may obtain a copy of the License at
9+
10+
http://www.apache.org/licenses/LICENSE-2.0
11+
12+
Unless required by applicable law or agreed to in writing, software
13+
distributed under the License is distributed on an "AS IS" BASIS,
14+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15+
See the License for the specific language governing permissions and
16+
limitations under the License.
17+
18+
19+

MANIFEST.in

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
include AUTHORS.rst
2+
include CONTRIBUTING.rst
3+
include HISTORY.rst
4+
include LICENSE
5+
include README.rst
6+
recursive-include django_elasticsearch_dsl *.html *.png *.gif *js *.css *jpg *jpeg *svg *py

Makefile

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
.PHONY: clean-pyc clean-build docs help
2+
.DEFAULT_GOAL := help
3+
define BROWSER_PYSCRIPT
4+
import os, webbrowser, sys
5+
try:
6+
from urllib import pathname2url
7+
except:
8+
from urllib.request import pathname2url
9+
10+
webbrowser.open("file://" + pathname2url(os.path.abspath(sys.argv[1])))
11+
endef
12+
export BROWSER_PYSCRIPT
13+
BROWSER := python -c "$$BROWSER_PYSCRIPT"
14+
15+
help:
16+
@perl -nle'print $& if m{^[a-zA-Z_-]+:.*?## .*$$}' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-25s\033[0m %s\n", $$1, $$2}'
17+
18+
clean: clean-build clean-pyc
19+
20+
clean-build: ## remove build artifacts
21+
rm -fr build/
22+
rm -fr dist/
23+
rm -fr *.egg-info
24+
25+
clean-pyc: ## remove Python file artifacts
26+
find . -name '*.pyc' -exec rm -f {} +
27+
find . -name '*.pyo' -exec rm -f {} +
28+
find . -name '*~' -exec rm -f {} +
29+
30+
lint: ## check style with flake8
31+
flake8 django_elasticsearch_dsl tests
32+
33+
test: ## run tests quickly with the default Python
34+
python runtests.py tests
35+
36+
test-all: ## run tests on every Python version with tox
37+
tox
38+
39+
coverage: ## check code coverage quickly with the default Python
40+
coverage run --source django_elasticsearch_dsl runtests.py tests
41+
coverage report -m
42+
coverage html
43+
$(BROWSER) htmlcov/index.html
44+
45+
docs: ## generate Sphinx HTML documentation, including API docs
46+
rm -f docs/django-elasticsearch-dsl.rst
47+
rm -f docs/modules.rst
48+
sphinx-apidoc -o docs/ django_elasticsearch_dsl
49+
$(MAKE) -C docs clean
50+
$(MAKE) -C docs html
51+
$(BROWSER) docs/_build/html/index.html
52+
53+
release: clean ## package and upload a release
54+
python setup.py sdist upload
55+
python setup.py bdist_wheel upload
56+
57+
sdist: clean ## package
58+
python setup.py sdist
59+
ls -l dist

0 commit comments

Comments
 (0)