added pre commit hooks and some other workflow stuff

This commit is contained in:
vabene1111 2021-01-14 00:00:26 +01:00
parent 50829dce47
commit d99e523608
11 changed files with 730 additions and 694 deletions

30
.pre-commit-config.yaml Normal file
View File

@ -0,0 +1,30 @@
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: local
hooks:
- id: pre-commit-yarn-build
name: Build javascript files
entry: yarn --cwd ./vue build
language: system
types: [ python ]
pass_filenames: false
#- id: pre-commit-django-migrations
# name: Check django migrations
# entry: bash -c './venv/bin/activate && ./manage.py makemigrations --check'
# language: system
# types: [ python ]
# pass_filenames: false
# - id: pre-commit-django-make-messages
# name: Make messages if necessary
# entry: ./manage.py makemessages -i venv -a
# language: system
# types: [ python ]
# pass_filenames: false
# - id: pre-commit-django-compile-messages
# name: Compile messages if necessary
# entry: ./manage.py compilemessages -i venv
# language: system
# types: [ python ]
# pass_filenames: false

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

View File

@ -149,7 +149,7 @@ class TestEditsRecipe(TestViews):
r = self.user_client_1.post(
url,
{'name': 'Test', 'working_time': 15, 'waiting_time': 15, }
{'name': 'Test', 'working_time': 15, 'waiting_time': 15, 'servings': 1, }
)
recipe.refresh_from_db()
self.assertEqual(recipe.working_time, 15)

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2020-12-26 13:48+0100\n"
"POT-Creation-Date: 2021-01-13 23:31+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@ -18,30 +18,34 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#: recipes/settings.py:175
#: .\recipes\settings.py:196
msgid "English"
msgstr "Englisch"
#: recipes/settings.py:176
#: .\recipes\settings.py:197
msgid "German"
msgstr "Deutsch"
#: recipes/settings.py:177
#: .\recipes\settings.py:198
msgid "Dutch"
msgstr ""
#: recipes/settings.py:178
#: .\recipes\settings.py:199
msgid "French"
msgstr ""
#: recipes/settings.py:179
#: .\recipes\settings.py:200
msgid "Catalan"
msgstr ""
#: recipes/settings.py:180
#: .\recipes\settings.py:201
msgid "Spanish"
msgstr ""
#: recipes/settings.py:181
#: .\recipes\settings.py:202
msgid "Italian"
msgstr ""
#: .\recipes\settings.py:203
msgid "Latvian"
msgstr ""

View File

@ -29,4 +29,5 @@ microdata==0.7.1
django-random-queryset==0.1.3
Jinja2==2.11.2
django-webpack-loader==0.7.0
django-js-reverse==0.9.1
django-js-reverse==0.9.1
pre-commit==2.9.3

View File

@ -60,7 +60,7 @@
</b-link>
</div>
<div class="col-2" style="text-align: right">
<div class="col-1" style="text-align: right">
<b-button @click="details_visible = !details_visible" style="border: none; background: none"
class="shadow-none" :class="{ 'text-primary': details_visible, 'text-success': !details_visible}">
<i class="far fa-check-circle"></i>