Skip to content

Commit 520563e

Browse files
committed
Merge branch 'master' into improv/antlr4-10
Signed-off-by: David ML Brown Jr <dmlb2000@gmail.com>
2 parents e19b16e + 9464fc9 commit 520563e

35 files changed

+1385
-985
lines changed

.github/workflows/pre-commit.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: Run Pre-Commit
2+
3+
on:
4+
pull_request: {}
5+
push:
6+
branches: [main]
7+
8+
jobs:
9+
pre-commit:
10+
runs-on: ${{ matrix.os }}
11+
strategy:
12+
matrix:
13+
os: [ubuntu-latest]
14+
python-version: ['3.8', '3.9']
15+
steps:
16+
- uses: actions/checkout@v2
17+
- uses: actions/setup-python@v3
18+
with:
19+
python-version: ${{ matrix.python-version }}
20+
- uses: pre-commit/action@v2.0.3

.github/workflows/pypi.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Publish to PyPi
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
tags:
8+
- v*
9+
10+
jobs:
11+
deploy:
12+
runs-on: ${{ matrix.os }}
13+
strategy:
14+
matrix:
15+
os: [ubuntu-latest]
16+
python-version: ['3.10']
17+
steps:
18+
- name: Publish package
19+
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
20+
uses: pypa/gh-action-pypi-publish@release/v1
21+
with:
22+
user: __token__
23+
password: ${{ secrets.PYPI_API_TOKEN }}

.github/workflows/pytest.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Run PyTest
2+
3+
on:
4+
pull_request: {}
5+
push:
6+
branches: [main]
7+
8+
jobs:
9+
build:
10+
runs-on: ${{ matrix.os }}
11+
strategy:
12+
matrix:
13+
os: [ubuntu-latest, macos-latest, windows-latest]
14+
python-version: ['3.8', '3.9', '3.10']
15+
exclude:
16+
- os: macos-latest
17+
python-version: '3.8'
18+
steps:
19+
- uses: actions/checkout@v3
20+
- name: Set up Python
21+
uses: actions/setup-python@v3
22+
with:
23+
python-version: ${{ matrix.python-version }}
24+
- name: Display Python version
25+
run: |
26+
python --version
27+
pip --version
28+
pip install coverage pep257 pre-commit pylint pytest readthedocs-sphinx-ext recommonmark setuptools sphinx sphinx-rtd-theme wheel
29+
pip install .
30+
cd tests
31+
coverage run --include='*/site-packages/jsonpath2/*' --omit='*/site-packages/jsonpath2/parser/JSONPath*' -m pytest -xv
32+
coverage report -m --fail-under 100
33+
cd ..
34+
python setup.py bdist_wheel
35+
python setup.py sdist

.github/workflows/sphinx.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Run Sphinx Test
2+
3+
on:
4+
pull_request: {}
5+
push:
6+
branches: [main]
7+
8+
jobs:
9+
build:
10+
runs-on: ${{ matrix.os }}
11+
strategy:
12+
matrix:
13+
os: [ubuntu-latest, macos-latest, windows-latest]
14+
python-version: ['3.8', '3.9', '3.10',]
15+
exclude:
16+
- os: macos-latest
17+
python-version: '3.8'
18+
19+
steps:
20+
- uses: actions/checkout@v3
21+
- name: Set up Python
22+
uses: actions/setup-python@v3
23+
with:
24+
python-version: ${{ matrix.python-version }}
25+
- name: Display Python version
26+
run: |
27+
python --version
28+
pip --version
29+
pip install coverage pep257 pre-commit pylint pytest readthedocs-sphinx-ext recommonmark setuptools sphinx sphinx-rtd-theme docutils==0.16
30+
pip install .
31+
cd docs
32+
sphinx-build -T -E -b readthedocs -d _build/doctrees-readthedocs -D language=en . _build/html
33+
sphinx-build -T -b readthedocssinglehtmllocalmedia -d _build/doctrees-readthedocssinglehtmllocalmedia -D language=en . _build/localmedia
34+
sphinx-build -b latex -D language=en -d _build/doctrees . _build/latex
35+
sphinx-build -T -b epub -d _build/doctrees-epub -D language=en . _build/epub

.pre-commit-config.yaml

Lines changed: 34 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -1,55 +1,40 @@
11
exclude: 'jsonpath2/parser/JSONPath.*'
22
repos:
3-
- repo: https://github.com/pre-commit/mirrors-autopep8
4-
rev: v1.5.2
5-
hooks:
6-
- id: autopep8
7-
- repo: https://github.com/pre-commit/pre-commit-hooks
3+
- repo: https://github.com/pre-commit/pre-commit-hooks
84
rev: v2.5.0
95
hooks:
10-
- id: fix-encoding-pragma
11-
- id: trailing-whitespace
12-
- id: flake8
13-
args: [--max-line-length=120]
14-
- id: check-merge-conflict
15-
- id: double-quote-string-fixer
16-
- id: end-of-file-fixer
17-
- id: debug-statements
18-
- id: check-added-large-files
19-
- id: check-ast
20-
- id: check-byte-order-marker
21-
- id: check-case-conflict
22-
- id: check-docstring-first
23-
- id: check-executables-have-shebangs
24-
types: [python]
25-
- id: check-json
26-
- id: check-vcs-permalinks
27-
- id: mixed-line-ending
28-
- id: name-tests-test
29-
- id: pretty-format-json
30-
args:
31-
- --autofix
32-
- --top-keys=_id
33-
- id: sort-simple-yaml
34-
files: '.yaml$'
35-
- id: check-symlinks
36-
- id: check-yaml
37-
- id: detect-private-key
38-
- id: trailing-whitespace
39-
- repo: local
6+
- id: fix-encoding-pragma
7+
- id: trailing-whitespace
8+
- id: check-merge-conflict
9+
- id: end-of-file-fixer
10+
- id: debug-statements
11+
- id: check-added-large-files
12+
- id: check-ast
13+
- id: check-byte-order-marker
14+
- id: check-case-conflict
15+
- id: check-docstring-first
16+
- id: check-executables-have-shebangs
17+
types: [python]
18+
- id: check-json
19+
- id: check-vcs-permalinks
20+
- id: mixed-line-ending
21+
- id: name-tests-test
22+
- id: pretty-format-json
23+
args:
24+
- --autofix
25+
- --top-keys=_id
26+
- id: sort-simple-yaml
27+
files: '.yaml$'
28+
- id: check-symlinks
29+
- id: check-yaml
30+
- id: detect-private-key
31+
- id: trailing-whitespace
32+
- repo: https://github.com/psf/black
33+
rev: 22.3.0
4034
hooks:
41-
- id: pep257
42-
name: pep257
43-
entry: python -m pep257
44-
language: system
45-
types: [python]
46-
- id: pylint
47-
name: pylint
48-
entry: python -m pylint --rcfile=pylintrc
49-
language: system
50-
types: [python]
51-
- repo: https://github.com/Lucas-C/pre-commit-hooks
52-
rev: v1.1.7
35+
- id: black
36+
- repo: https://github.com/Lucas-C/pre-commit-hooks
37+
rev: v1.1.13
5338
hooks:
54-
- id: remove-tabs
55-
- id: remove-crlf
39+
- id: remove-tabs
40+
- id: remove-crlf

.travis.yml

Lines changed: 0 additions & 61 deletions
This file was deleted.

0 commit comments

Comments
 (0)