kopia lustrzana https://github.com/rtts/django-simplecms
Upgrade pre-commit hooks and reformat code
rodzic
94af72cca8
commit
20edda4936
|
@ -1,24 +1,11 @@
|
||||||
repos:
|
repos:
|
||||||
|
|
||||||
- repo: https://github.com/rtts/djhtml
|
|
||||||
rev: v1.5.2
|
|
||||||
hooks:
|
|
||||||
- id: djhtml
|
|
||||||
|
|
||||||
- repo: https://github.com/myint/autoflake
|
|
||||||
rev: v2.0.0
|
|
||||||
hooks:
|
|
||||||
- id: autoflake
|
|
||||||
args: ['--in-place', '--remove-all-unused-imports']
|
|
||||||
|
|
||||||
- repo: https://github.com/pycqa/isort
|
- repo: https://github.com/pycqa/isort
|
||||||
rev: 5.11.4
|
rev: 5.12.0
|
||||||
hooks:
|
hooks:
|
||||||
- id: isort
|
- id: isort
|
||||||
args: ['--resolve-all-configs', '--line-length', '88']
|
|
||||||
|
|
||||||
- repo: https://github.com/psf/black
|
- repo: https://github.com/psf/black
|
||||||
rev: 22.12.0
|
rev: 23.1.0
|
||||||
hooks:
|
hooks:
|
||||||
- id: black
|
- id: black
|
||||||
|
|
||||||
|
@ -26,3 +13,11 @@ repos:
|
||||||
rev: 6.0.0
|
rev: 6.0.0
|
||||||
hooks:
|
hooks:
|
||||||
- id: flake8
|
- id: flake8
|
||||||
|
|
||||||
|
- repo: https://github.com/rtts/djhtml
|
||||||
|
rev: 3.0.0
|
||||||
|
hooks:
|
||||||
|
- id: djhtml
|
||||||
|
- id: djcss
|
||||||
|
types: [scss]
|
||||||
|
- id: djjs
|
||||||
|
|
|
@ -3,9 +3,9 @@ import os
|
||||||
import re
|
import re
|
||||||
import shutil
|
import shutil
|
||||||
|
|
||||||
|
import cms
|
||||||
from pip._internal.operations import freeze as pip
|
from pip._internal.operations import freeze as pip
|
||||||
|
|
||||||
import cms
|
|
||||||
import example
|
import example
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,10 +1,9 @@
|
||||||
|
from cms import registry
|
||||||
from django import template
|
from django import template
|
||||||
from django.shortcuts import reverse
|
from django.shortcuts import reverse
|
||||||
from django.utils.safestring import mark_safe
|
from django.utils.safestring import mark_safe
|
||||||
from markdown import markdown as md
|
from markdown import markdown as md
|
||||||
|
|
||||||
from cms import registry
|
|
||||||
|
|
||||||
MARKDOWN_EXTENSIONS = ["extra", "smarty"]
|
MARKDOWN_EXTENSIONS = ["extra", "smarty"]
|
||||||
register = template.Library()
|
register = template.Library()
|
||||||
|
|
||||||
|
|
|
@ -1,2 +1,3 @@
|
||||||
[tool.isort]
|
[build-system]
|
||||||
profile = "black"
|
requires = ["setuptools"]
|
||||||
|
build-backend = "setuptools.build_meta"
|
||||||
|
|
|
@ -1,4 +1,7 @@
|
||||||
[flake8]
|
[flake8]
|
||||||
max-line-length = 88
|
max-line-length = 88
|
||||||
select = C,E,F,W,B,B950
|
extend-ignore = E203
|
||||||
extend-ignore = E203, E501
|
|
||||||
|
[isort]
|
||||||
|
profile = black
|
||||||
|
known_third_party = cms
|
||||||
|
|
9
setup.py
9
setup.py
|
@ -1,7 +1,6 @@
|
||||||
#!/usr/bin/env python
|
#!/usr/bin/env python
|
||||||
from setuptools import find_packages, setup
|
|
||||||
|
|
||||||
import cms
|
import cms
|
||||||
|
from setuptools import find_packages, setup
|
||||||
|
|
||||||
with open("README.md", "r") as fh:
|
with open("README.md", "r") as fh:
|
||||||
long_description = fh.read()
|
long_description = fh.read()
|
||||||
|
@ -22,7 +21,10 @@ setup(
|
||||||
include_package_data=True,
|
include_package_data=True,
|
||||||
classifiers=[
|
classifiers=[
|
||||||
"Programming Language :: Python :: 3",
|
"Programming Language :: Python :: 3",
|
||||||
"License :: OSI Approved :: GNU Affero General Public License v3 or later (AGPLv3+)",
|
(
|
||||||
|
"License :: OSI Approved :: GNU Affero General Public License v3 or later"
|
||||||
|
" (AGPLv3+)"
|
||||||
|
),
|
||||||
"Operating System :: OS Independent",
|
"Operating System :: OS Independent",
|
||||||
],
|
],
|
||||||
python_requires=">=3.8",
|
python_requires=">=3.8",
|
||||||
|
@ -34,7 +36,6 @@ setup(
|
||||||
"easy-thumbnails",
|
"easy-thumbnails",
|
||||||
"libsass",
|
"libsass",
|
||||||
"markdown",
|
"markdown",
|
||||||
"pre-commit",
|
|
||||||
"psycopg2",
|
"psycopg2",
|
||||||
"pylibmc",
|
"pylibmc",
|
||||||
],
|
],
|
||||||
|
|
Ładowanie…
Reference in New Issue