-
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.
Merge pull request #1 from alexferl/add_pipfile
add pipfile and falcon 3
- Loading branch information
Showing
17 changed files
with
462 additions
and
103 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,62 @@ | ||
name: Test | ||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
branches: | ||
- master | ||
jobs: | ||
build: | ||
runs-on: '${{ matrix.os }}' | ||
strategy: | ||
matrix: | ||
include: | ||
- os: ubuntu-latest | ||
python-version: '3.8' | ||
FALCON: 3.1.1 | ||
- os: ubuntu-latest | ||
python-version: '3.8' | ||
FALCON: 3.0.1 | ||
- os: ubuntu-latest | ||
python-version: '3.8' | ||
FALCON: 2.0.0 | ||
- os: ubuntu-latest | ||
python-version: '3.9' | ||
FALCON: 3.1.1 | ||
- os: ubuntu-latest | ||
python-version: '3.9' | ||
FALCON: 3.0.1 | ||
- os: ubuntu-latest | ||
python-version: '3.9' | ||
FALCON: 2.0.0 | ||
- os: ubuntu-latest | ||
python-version: '3.10' | ||
FALCON: 3.1.1 | ||
- os: ubuntu-latest | ||
python-version: '3.10' | ||
FALCON: 3.0.1 | ||
- os: ubuntu-latest | ||
python-version: '3.10' | ||
FALCON: 2.0.0 | ||
- os: ubuntu-latest | ||
python-version: '3.11' | ||
FALCON: 3.1.1 | ||
- os: ubuntu-latest | ||
python-version: '3.11' | ||
FALCON: 3.0.1 | ||
- os: ubuntu-latest | ||
python-version: '3.11' | ||
FALCON: 2.0.0 | ||
steps: | ||
- name: 'Set up Python ${{ matrix.python-version }}' | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: '${{ matrix.python-version }}' | ||
- uses: actions/checkout@v2 | ||
- run: pip install FALCON==$FALCON | ||
env: | ||
FALCON: '${{ matrix.FALCON }}' | ||
- run: pip install -r requirements-dev.txt . | ||
- run: pip install . | ||
- run: pytest |
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 |
---|---|---|
|
@@ -45,6 +45,7 @@ nosetests.xml | |
coverage.xml | ||
*,cover | ||
.hypothesis/ | ||
.pytest_cache | ||
|
||
# Translations | ||
*.mo | ||
|
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,9 +1,21 @@ | ||
repos: | ||
- repo: local | ||
hooks: | ||
- id: black | ||
name: black | ||
stages: [commit] | ||
language: system | ||
entry: venv/bin/black -t py37 --exclude venv . | ||
types: [python] | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v4.4.0 | ||
hooks: | ||
- id: trailing-whitespace | ||
- id: end-of-file-fixer | ||
- id: mixed-line-ending | ||
args: ['--fix=lf'] | ||
description: Forces to replace line ending by the UNIX 'lf' character. | ||
- repo: https://github.com/psf/black | ||
rev: 23.9.1 | ||
hooks: | ||
- id: black | ||
language_version: python3 | ||
- repo: https://github.com/d-ryzhykau/pipenv-lock-pre-commit | ||
rev: 0.5.0 | ||
hooks: | ||
- id: pipenv-lock | ||
- id: pipenv-verify | ||
- id: pipenv-requirements | ||
- id: pipenv-requirements-dev |
This file was deleted.
Oops, something went wrong.
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,42 +1,24 @@ | ||
.PHONY: help build clean update test lint | ||
|
||
VENV_NAME?=venv | ||
VENV_ACTIVATE=. $(VENV_NAME)/bin/activate | ||
PYTHON=${VENV_NAME}/bin/python3 | ||
.PHONY: help dev test lint pre-commit | ||
|
||
.DEFAULT: help | ||
help: | ||
@echo "make build" | ||
@echo " prepare development environment, use only once" | ||
@echo "make clean" | ||
@echo " delete development environment" | ||
@echo "make update" | ||
@echo " update dependencies" | ||
@echo "make dev" | ||
@echo " prepare development environment" | ||
@echo "make test" | ||
@echo " run tests" | ||
@echo " run tests" | ||
@echo "make lint" | ||
@echo " run black" | ||
|
||
build: | ||
make venv | ||
|
||
venv: $(VENV_NAME)/bin/activate | ||
$(VENV_NAME)/bin/activate: | ||
test -d $(VENV_NAME) || virtualenv -p python3 $(VENV_NAME) | ||
${PYTHON} -m pip install -U pip | ||
${PYTHON} -m pip install -r dev_requirements.txt | ||
$(VENV_NAME)/bin/pre-commit install | ||
touch $(VENV_NAME)/bin/activate | ||
|
||
clean: | ||
rm -rf venv | ||
@echo " run black" | ||
@echo "make pre-commit" | ||
@echo " run pre-commit hooks" | ||
|
||
update: | ||
${PYTHON} -m pip install -r dev_requirements.txt | ||
dev: | ||
pipenv install --dev | ||
|
||
test: venv | ||
${PYTHON} -m pytest | ||
test: | ||
pipenv run pytest | ||
|
||
lint: venv | ||
$(VENV_NAME)/bin/black -t py37 --exclude $(VENV_NAME) . | ||
lint: | ||
pipenv run black . | ||
|
||
pre-commit: | ||
pipenv run pre-commit |
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 @@ | ||
[[source]] | ||
url = "https://pypi.org/simple" | ||
verify_ssl = true | ||
name = "pypi" | ||
|
||
[packages] | ||
falcon = "==3.0.0" | ||
|
||
[dev-packages] | ||
black = "==23.9.1" | ||
pre-commit = "==3.4.0" | ||
pytest = "==7.4.2" |
Oops, something went wrong.