Skip to content

Commit

Permalink
Merge pull request #70 from moshthepitt/wtf
Browse files Browse the repository at this point in the history
QoL Updates
  • Loading branch information
moshthepitt authored Jun 26, 2020
2 parents 31f8155 + d252dc3 commit ebf361d
Show file tree
Hide file tree
Showing 8 changed files with 97 additions and 74 deletions.
6 changes: 6 additions & 0 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name-template: v$NEXT_PATCH_VERSION
tag-template: v$NEXT_PATCH_VERSION
template: |
## What’s Changed
$CHANGES
20 changes: 15 additions & 5 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,22 +1,32 @@
exclude: '/snapshots/'
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v2.2.3
rev: v3.1.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: flake8
- id: check-docstring-first
- id: debug-statements
- id: detect-private-key
- id: check-added-large-files

- repo: https://github.com/pre-commit/mirrors-isort
rev: v4.3.20
rev: v4.3.21
hooks:
- id: isort

- repo: https://github.com/python/black
rev: 19.3b0
rev: 19.10b0
hooks:
- id: black
language_version: python3.6

- repo: https://gitlab.com/pycqa/flake8
rev: 3.8.3
hooks:
- id: flake8
language_version: python3.6

- repo: local
hooks:
- id: pylint
Expand All @@ -26,6 +36,6 @@ repos:
files: \.py$

- repo: https://github.com/pre-commit/mirrors-mypy
rev: v0.701
rev: v0.782
hooks:
- id: mypy
2 changes: 2 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,5 @@ include LICENSE
include README.md
recursive-include vega_admin/static *
recursive-include vega_admin/templates *

recursive-exclude tests *
110 changes: 54 additions & 56 deletions requirements/dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,88 +5,86 @@
# pip-compile requirements/dev.in
#

appdirs==1.4.3 # via black, virtualenv
asgiref==3.2.3 # via django
aspy.yaml==1.3.0 # via pre-commit
astroid==2.3.3 # via pylint
appdirs==1.4.4 # via black, virtualenv
asgiref==3.2.10 # via django
astroid==2.4.2 # via pylint
attrs==19.3.0 # via black
autopep8==1.5
backcall==0.1.0 # via ipython
autopep8==1.5.3
backcall==0.2.0 # via ipython
black==19.10b0
certifi==2019.11.28 # via requests
cfgv==3.0.0 # via pre-commit
certifi==2020.6.20 # via requests
cfgv==3.1.0 # via pre-commit
chardet==3.0.4 # via requests
click==7.0 # via black
coverage==5.0.3
decorator==4.4.1 # via ipython, traitlets
click==7.1.2 # via black
coverage==5.1
decorator==4.4.2 # via ipython, traitlets
defusedxml==0.6.0 # via python3-openid
distlib==0.3.0 # via virtualenv
django-allauth==0.41.0
django-allauth==0.42.0
django-braces==1.14.0
django-crispy-forms==1.8.1
django-filter==2.2.0
django-tables2==2.2.1
django==3.0.3 # via django-allauth, django-braces, django-filter, django-tables2, model-mommy
entrypoints==0.3 # via flake8
django-crispy-forms==1.9.1
django-filter==2.3.0
django-tables2==2.3.1
django==3.0.7 # via django-allauth, django-braces, django-filter, django-tables2, model-mommy
filelock==3.0.12 # via tox, virtualenv
flake8==3.7.9
identify==1.4.11 # via pre-commit
idna==2.8 # via requests
importlib-metadata==1.5.0 # via pluggy, pre-commit, tox, virtualenv
importlib-resources==1.0.2 # via pre-commit, virtualenv
ipdb==0.12.3
flake8==3.8.3
identify==1.4.20 # via pre-commit
idna==2.9 # via requests
importlib-metadata==1.6.1 # via flake8, importlib-resources, pluggy, pre-commit, tox, virtualenv
importlib-resources==2.0.1 # via pre-commit, virtualenv
ipdb==0.13.3
ipython-genutils==0.2.0 # via traitlets
ipython==7.12.0 # via ipdb
ipython==7.15.0 # via ipdb
isort==4.3.21
jedi==0.16.0 # via ipython
jedi==0.17.1 # via ipython
lazy-object-proxy==1.4.3 # via astroid
mccabe==0.6.1 # via flake8, pylint
model-mommy==2.0.0
mypy-extensions==0.4.3 # via mypy
mypy==0.761
nodeenv==1.3.5 # via pre-commit
mypy==0.782
nodeenv==1.4.0 # via pre-commit
oauthlib==3.1.0 # via requests-oauthlib
packaging==20.1 # via tox
parso==0.6.1 # via jedi
pathspec==0.7.0 # via black
packaging==20.4 # via tox
parso==0.7.0 # via jedi
pathspec==0.8.0 # via black
pep8==1.7.1
pexpect==4.8.0 # via ipython
pickleshare==0.7.5 # via ipython
pluggy==0.13.1 # via tox
pre-commit==2.0.1
prompt-toolkit==3.0.3 # via ipython
psycopg2-binary==2.8.4
pre-commit==2.5.1
prompt-toolkit==3.0.5 # via ipython
psycopg2-binary==2.8.5
ptyprocess==0.6.0 # via pexpect
py==1.8.1 # via tox
pycodestyle==2.5.0
py==1.9.0 # via tox
pycodestyle==2.6.0
pydocstyle==5.0.2
pyflakes==2.1.1 # via flake8
pygments==2.5.2 # via ipython
pylint-django==2.0.13
pyflakes==2.2.0 # via flake8
pygments==2.6.1 # via ipython
pylint-django==2.0.15
pylint-plugin-utils==0.6 # via pylint-django
pylint==2.4.4
pyparsing==2.4.6 # via packaging
pylint==2.5.3
pyparsing==2.4.7 # via packaging
python3-openid==3.1.0 # via django-allauth
pytz==2019.3 # via django
pyyaml==5.3 # via aspy.yaml, pre-commit
regex==2020.1.8 # via black
pytz==2020.1 # via django
pyyaml==5.3.1 # via pre-commit
regex==2020.6.8 # via black
requests-oauthlib==1.3.0 # via django-allauth
requests==2.22.0 # via django-allauth, requests-oauthlib
six==1.14.0 # via astroid, django-braces, packaging, tox, traitlets, virtualenv
requests==2.24.0 # via django-allauth, requests-oauthlib
six==1.15.0 # via astroid, django-braces, packaging, tox, traitlets, virtualenv
snowballstemmer==2.0.0 # via pydocstyle
sqlparse==0.3.0 # via django
tablib==1.0.0
toml==0.10.0 # via black, pre-commit, tox
tox==3.14.4
sqlparse==0.3.1 # via django
tablib==2.0.0
toml==0.10.1 # via autopep8, black, pre-commit, pylint, tox
tox==3.15.2
traitlets==4.3.3 # via ipython
typed-ast==1.4.1 # via astroid, black, mypy
typing-extensions==3.7.4.1 # via mypy
urllib3==1.25.8 # via requests
virtualenv==20.0.3 # via pre-commit, tox
wcwidth==0.1.8 # via prompt-toolkit
wrapt==1.11.2 # via astroid
yapf==0.29.0
zipp==2.2.0 # via importlib-metadata
typing-extensions==3.7.4.2 # via mypy
urllib3==1.25.9 # via requests
virtualenv==20.0.25 # via pre-commit, tox
wcwidth==0.2.5 # via prompt-toolkit
wrapt==1.12.1 # via astroid
yapf==0.30.0
zipp==3.1.0 # via importlib-metadata, importlib-resources

# The following packages are considered to be unsafe in a requirements file:
# setuptools
3 changes: 2 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
if os.system("pip freeze | grep twine"):
print("twine not installed.\nUse `pip install twine`.\nExiting.")
sys.exit()
os.system("rm -rf build/ *.egg-info/")
os.system("python setup.py sdist bdist_wheel")
os.system("twine upload dist/* --skip-existing")
print("You probably want to also tag the version now:")
Expand All @@ -32,7 +33,7 @@
author="Kelvin Jayanoris",
author_email="[email protected]",
url="https://github.com/moshthepitt/django-vega-admin",
packages=find_packages(exclude=["docs", "tests"]),
packages=find_packages(exclude=["docs", "*.egg-info", "build", "tests.*", "tests"]),
install_requires=[
"Django >=2.2",
"django-crispy-forms",
Expand Down
6 changes: 6 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,12 @@ commands =
pip install -r requirements/dev.txt
pylint --rcfile={toxinidir}/.pylintrc {toxinidir}/vega_admin

[testenv:mypy]
basepython = python3.6
commands =
pip install -r requirements/dev.txt
mypy -m vega_admin

[testenv]
deps =
coverage
Expand Down
2 changes: 1 addition & 1 deletion vega_admin/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
"""Main init file for vega_admin."""
VERSION = (0, 0, 18)
VERSION = (0, 0, 19)
__version__ = ".".join(str(v) for v in VERSION)
# pylint: disable=invalid-name
default_app_config = "vega_admin.apps.VegaAdminConfig" # noqa
22 changes: 11 additions & 11 deletions vega_admin/templates/vega_admin/badmin/base.html
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
<!DOCTYPE html>
{% load staticfiles i18n %}
{% load static i18n %}
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>{% block title %}{% endblock %}</title>
{% block meta_keywords %}<meta name="keywords" content="{% block meta_keywords_content %}{% endblock %}" />{% endblock %}
{% block meta_description %}<meta name="description" content="{% block meta_description_content %}{% endblock %}" />{% endblock %}
{% block meta_description %}<meta name="description" content="{% block meta_description_content %}{% endblock %}" />{% endblock %}
{% block other_meta %}{% endblock %}

{% block css %}
<link rel="stylesheet" type="text/css" href="{% static 'badmin/bootstrap/css/bootstrap.min.css' %}" />
<link rel="stylesheet" type="text/css" href="{% static 'badmin/css/styles.css' %}" />
<link rel="stylesheet" type="text/css" href="{% static 'badmin/bootstrap/css/bootstrap.min.css' %}" />
<link rel="stylesheet" type="text/css" href="{% static 'badmin/css/styles.css' %}" />
{% block extracss %}{% endblock %}
{% endblock %}
{% endblock %}

{% block extrahead %}{% endblock %}
<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
Expand Down Expand Up @@ -52,9 +52,9 @@ <h1><a href="/">Vega Admin</a></h1>
{{ message }}
</div>
{% endfor %}
{% endif %}
{% endif %}
</div>
</div>
</div>
{% endblock %}
{% block page_content %}
<div class="row page-content">
Expand All @@ -71,20 +71,20 @@ <h1><a href="/">Vega Admin</a></h1>
</div>
</div>
<footer>
<div class="container">
<div class="container">
<div class="copy text-center">
&copy; Vega Admin {% trans "2018" %} - {% now "Y" %}
</div>
</div>
</div>
</footer>
{% block js %}
<script src="{% static 'badmin/js/jquery-2.2.4.min.js' %}"></script>
<script src="{% static 'badmin/bootstrap/js/bootstrap.min.js' %}"></script>
<script src="{% static 'badmin/js/custom.js' %}"></script>
<script src="{% static 'badmin/js/custom.js' %}"></script>
<!-- IE10 viewport hack for Surface/desktop Windows 8 bug -->
<script src="{% static 'badmin/js/ie10-viewport-bug-workaround.js' %}"></script>
{% block extrajs %}{% endblock %}
{% endblock %}
{% block footerjs %}{% endblock %}
</body>
</html>
</html>

0 comments on commit ebf361d

Please sign in to comment.