From 4c97db3c0957972662bd85d7de97deeb7f439ad1 Mon Sep 17 00:00:00 2001 From: JasonHomeWorkstationUbuntu Date: Sun, 18 Oct 2020 22:54:15 +1100 Subject: [PATCH] Copied all repo config file from Author's original repo --- .flake8 | 7 +++ .gitconfig | 7 +++ .gitignore | 107 ++++++++++++++++++++++++++++++++++++++++ .isort.cfg | 12 +++++ .pre-commit-config.yaml | 34 +++++++++++++ pyproject.toml | 3 ++ requirements.txt | 10 ++++ 7 files changed, 180 insertions(+) create mode 100644 .flake8 create mode 100644 .gitconfig create mode 100644 .gitignore create mode 100644 .isort.cfg create mode 100644 .pre-commit-config.yaml create mode 100644 pyproject.toml create mode 100644 requirements.txt diff --git a/.flake8 b/.flake8 new file mode 100644 index 0000000..288df28 --- /dev/null +++ b/.flake8 @@ -0,0 +1,7 @@ +[flake8] +exclude=settings.py, wsgi.py, manage.py, */migrations/* +ignore = B950, D104, D105, D106, D400, E203, E266, E501, N803, N806, W503 +max-complexity = 10 +max-line-length = 60 +select = B, B9, C, D, E, F, N, W +ignore-names = setUp, tearDown, setUpClass, tearDownClass, setUpTestData diff --git a/.gitconfig b/.gitconfig new file mode 100644 index 0000000..704bd4b --- /dev/null +++ b/.gitconfig @@ -0,0 +1,7 @@ +[alias] + prev = checkout HEAD^ + next = !git checkout `git rev-list HEAD..$(git branch --contains | tail -1) | tail -1` + ci = commit + co = checkout + st = status + ll = log --oneline diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..66114a8 --- /dev/null +++ b/.gitignore @@ -0,0 +1,107 @@ +.docker-env + +# https://github.com/github/gitignore/blob/master/Python.gitignore +# 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/ +*.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/ +.coverage +.coverage.* +.cache +nosetests.xml +coverage.xml +*.cover +.hypothesis/ +.pytest_cache/ + +# Translations +*.mo +*.pot + +# Django stuff: +*.log +local_settings.py +db.sqlite3 + +# Flask stuff: +instance/ +.webassets-cache + +# Scrapy stuff: +.scrapy + +# Sphinx documentation +docs/_build/ + +# PyBuilder +target/ + +# Jupyter Notebook +.ipynb_checkpoints + +# pyenv +.python-version + +# 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/ diff --git a/.isort.cfg b/.isort.cfg new file mode 100644 index 0000000..3ddf4aa --- /dev/null +++ b/.isort.cfg @@ -0,0 +1,12 @@ +[settings] +balanced_wrapping=true +combine_as_imports=true +force_add=true +force_grid_wrap=0 +include_trailing_comma=true +indent=' ' +line_length=60 +multi_line_output=3 +not_skip=__init__.py +known_third_party = django, django_extensions, environ, factory, faker, pytz, rest_framework, test_plus +known_first_party = blog, config, contact, organizer, suorganizer diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 0000000..0768163 --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,34 @@ +repos: +- repo: https://github.com/pre-commit/pre-commit-hooks + rev: v2.0.0 + hooks: + - id: check-added-large-files + args: [--maxkb=500] + - id: check-byte-order-marker + - id: check-case-conflict + - id: check-json + - id: check-merge-conflict + - id: check-symlinks + - id: debug-statements + - id: detect-private-key + - id: end-of-file-fixer + - id: mixed-line-ending + args: [--fix=lf] + - id: requirements-txt-fixer + - id: trailing-whitespace +- repo: https://github.com/pre-commit/mirrors-isort + rev: v4.3.4 + hooks: + - id: isort +- repo: https://github.com/ambv/black + rev: 18.9b0 + hooks: + - id: black + language_version: python3.6 +- repo: local + hooks: + - id: flake8 + entry: flake8 + language: system + name: flake8 + types: [python] diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000..0319153 --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,3 @@ +[tool.black] +line-length = 60 +py36 = true diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..f86b8ce --- /dev/null +++ b/requirements.txt @@ -0,0 +1,10 @@ +django-test-plus==1.1.1 +Django>=2.1,<2.2 +factory_boy==2.11.1 +Faker==0.9.2 +flake8==3.5.0 +flake8-bugbear==18.2.0 +flake8-docstrings==1.3.0 +pep8-naming==0.7.0 +pre-commit==1.10.4 +pytz==2018.5