Skip to content

Commit ec829a2

Browse files
committed
Start the repository for GraphQL-core-next
Copied everything from github.com/Cito to github.com/graphql-python.
0 parents  commit ec829a2

File tree

244 files changed

+42852
-0
lines changed

Some content is hidden

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

244 files changed

+42852
-0
lines changed

Diff for: .editorconfig

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# http://editorconfig.org
2+
3+
root = true
4+
5+
[*]
6+
indent_style = space
7+
indent_size = 4
8+
trim_trailing_whitespace = true
9+
insert_final_newline = true
10+
charset = utf-8
11+
end_of_line = lf
12+
13+
[*.bat]
14+
indent_style = tab
15+
end_of_line = crlf
16+
17+
[LICENSE]
18+
insert_final_newline = false
19+
20+
[Makefile]
21+
indent_style = tab

Diff for: .flake8

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[flake8]
2+
exclude = .git,.mypy_cache,.pytest_cache,.tox,.venv,__pycache__,build,dist,docs

Diff for: .gitignore

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
2+
.cache
3+
.coverage
4+
.env
5+
.idea
6+
.mypy_cache
7+
.pytest_cache
8+
.tox
9+
.venv
10+
11+
build
12+
dist
13+
docs/_build
14+
15+
__pycache__
16+
17+
*.egg-info
18+
*.py[cod]

Diff for: .mypy.ini

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[mypy]
2+
python_version = 3.6

Diff for: .travis.yml

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
language: python
2+
3+
python:
4+
- 3.6
5+
# - 3.7 done in the matrix below
6+
7+
install:
8+
- pip install pipenv
9+
- pipenv install --dev
10+
11+
matrix:
12+
include:
13+
- python: 3.7
14+
dist: xenial # required for Python 3.7,
15+
sudo: true # see travis-ci/travis-ci#9069
16+
17+
script:
18+
- flake8 graphql tests
19+
- mypy graphql
20+
- pytest --cov-report term-missing --cov=graphql
21+
22+
after_success:
23+
- coveralls

Diff for: LICENSE

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
MIT License
2+
3+
Copyright (c) 2017-2018 Facebook, Inc. (GraphQL.js)
4+
Copyright (c) 2016 Syrus Akbary (GraphQL-core)
5+
Copyright (c) 2018 Christoph Zwerschke (GraphQL-core-next)
6+
7+
Permission is hereby granted, free of charge, to any person obtaining a copy
8+
of this software and associated documentation files (the "Software"), to deal
9+
in the Software without restriction, including without limitation the rights
10+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11+
copies of the Software, and to permit persons to whom the Software is
12+
furnished to do so, subject to the following conditions:
13+
14+
The above copyright notice and this permission notice shall be included in all
15+
copies or substantial portions of the Software.
16+
17+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23+
SOFTWARE.

Diff for: MANIFEST.in

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
include LICENSE
2+
include README.md
3+
include Makefile
4+
include Pipfile
5+
include tox.ini
6+
7+
recursive-include graphql *
8+
recursive-include tests *
9+
recursive-exclude * __pycache__
10+
recursive-exclude * .mypy_cache
11+
recursive-exclude * *.py[co]
12+
13+
recursive-include docs *.rst conf.py Makefile make.bat *.jpg *.png *.gif

Diff for: Makefile

+88
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
.PHONY: clean clean-test clean-pyc clean-build docs help
2+
.DEFAULT_GOAL := help
3+
4+
define BROWSER_PYSCRIPT
5+
import os, webbrowser, sys
6+
7+
try:
8+
from urllib import pathname2url
9+
except:
10+
from urllib.request import pathname2url
11+
12+
webbrowser.open("file://" + pathname2url(os.path.abspath(sys.argv[1])))
13+
endef
14+
export BROWSER_PYSCRIPT
15+
16+
define PRINT_HELP_PYSCRIPT
17+
import re, sys
18+
19+
for line in sys.stdin:
20+
match = re.match(r'^([a-zA-Z_-]+):.*?## (.*)$$', line)
21+
if match:
22+
target, help = match.groups()
23+
print("%-20s %s" % (target, help))
24+
endef
25+
export PRINT_HELP_PYSCRIPT
26+
27+
BROWSER := python -c "$$BROWSER_PYSCRIPT"
28+
29+
help:
30+
@python -c "$$PRINT_HELP_PYSCRIPT" < $(MAKEFILE_LIST)
31+
32+
clean: clean-build clean-pyc clean-test ## remove all build, test, coverage and Python artifacts
33+
34+
clean-build: ## remove build artifacts
35+
rm -fr build/
36+
rm -fr dist/
37+
rm -fr .eggs/
38+
find . -name '*.egg-info' -exec rm -fr {} +
39+
find . -name '*.egg' -exec rm -f {} +
40+
41+
clean-pyc: ## remove Python file artifacts
42+
find . -name '*.pyc' -exec rm -f {} +
43+
find . -name '*.pyo' -exec rm -f {} +
44+
find . -name '*~' -exec rm -f {} +
45+
find . -name '__pycache__' -exec rm -fr {} +
46+
47+
clean-test: ## remove test and coverage artifacts
48+
rm -fr .tox/
49+
rm -f .coverage
50+
rm -fr htmlcov/
51+
rm -fr .pytest_cache
52+
53+
lint: ## check style with flake8
54+
flake8 graphql tests
55+
56+
test: ## run tests quickly with the default Python
57+
py.test
58+
59+
test-all: ## run tests on every Python version with tox
60+
tox
61+
62+
coverage: ## check code coverage quickly with the default Python
63+
coverage run --source graphql -m pytest
64+
coverage report -m
65+
coverage html
66+
$(BROWSER) htmlcov/index.html
67+
68+
docs: ## generate Sphinx HTML documentation, including API docs
69+
rm -f docs/graphql.rst
70+
rm -f docs/modules.rst
71+
sphinx-apidoc -o docs/ graphql
72+
$(MAKE) -C docs clean
73+
$(MAKE) -C docs html
74+
$(BROWSER) docs/_build/html/index.html
75+
76+
servedocs: docs ## compile the docs watching for changes
77+
watchmedo shell-command -p '*.rst' -c '$(MAKE) -C docs html' -R -D .
78+
79+
release: dist ## package and upload a release
80+
twine upload dist/*
81+
82+
dist: clean ## builds source and wheel package
83+
python setup.py sdist
84+
python setup.py bdist_wheel
85+
ls -l dist
86+
87+
install: clean ## install the package to the active Python's site-packages
88+
python setup.py install

Diff for: Pipfile

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
[[source]]
2+
url = "https://pypi.python.org/simple"
3+
verify_ssl = true
4+
name = "pypi"
5+
6+
[dev-packages]
7+
graphql-core-next = {path = ".", editable = true}
8+
flake8 = "*"
9+
mypy = "*"
10+
pytest = "*"
11+
pytest-describe = "*"
12+
pytest-asyncio = "*"
13+
tox = "*"
14+
sphinx = "*"
15+
sphinx_rtd_theme = "*"
16+
python-coveralls = "*"
17+
pytest-cov = "*"

0 commit comments

Comments
 (0)