-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
.coafile: Check yaml files and the templates #39
Conversation
Comment on c7a7ee4, file templates/Language.html.jinja2, line 17. Variable blocks should be spaced with Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpo9b7vard/templates/Language.html.jinja2
+++ b/tmp/tmpo9b7vard/templates/Language.html.jinja2
@@ -14,7 +14,7 @@
<tr>
<th>Grammar File</th>
<td>
- <a href = {{language.grammar_file}}>
+ <a href = {{ language.grammar_file }}>
{{ m.show_grammar(language.grammar_file) }}
</a>
</td> |
Comment on c7a7ee4, file templates/macros.jinja2, line 6. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpo9b7vard/templates/macros.jinja2
+++ b/tmp/tmpo9b7vard/templates/macros.jinja2
@@ -3,7 +3,7 @@
{{ language.full_name }}
{% else %}
{{ language.identifier }}
-{% endif %}
+{% endif %}{# if language.full_name #}
{% endmacro %}
{% macro show_grammar(grammar_file) %} |
Comment on c7a7ee4, file templates/macros.jinja2, line 10. Variable blocks should be spaced with Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpo9b7vard/templates/macros.jinja2
+++ b/tmp/tmpo9b7vard/templates/macros.jinja2
@@ -7,7 +7,7 @@
{% endmacro %}
{% macro show_grammar(grammar_file) %}
- {{grammar_file}}
+ {{ grammar_file }}
{% endmacro %}
{% macro show_list(list, separator=',') %} |
Comment on c7a7ee4, file templates/macros.jinja2, line 15. Variable blocks should be spaced with Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpo9b7vard/templates/macros.jinja2
+++ b/tmp/tmpo9b7vard/templates/macros.jinja2
@@ -12,7 +12,7 @@
{% macro show_list(list, separator=',') %}
{% for item in list %}
- {{ item.pk | escape }}{% if not loop.last %}{{separator}} {% endif %}
+ {{ item.pk | escape }}{% if not loop.last %}{{ separator }} {% endif %}
{% endfor %}
{% endmacro %}
|
Comment on c7a7ee4, file templates/macros.jinja2, line 16. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpo9b7vard/templates/macros.jinja2
+++ b/tmp/tmpo9b7vard/templates/macros.jinja2
@@ -13,7 +13,7 @@
{% macro show_list(list, separator=',') %}
{% for item in list %}
{{ item.pk | escape }}{% if not loop.last %}{{separator}} {% endif %}
- {% endfor %}
+ {% endfor %}{# for item in list #}
{% endmacro %}
{% macro show_delimiter_list(delimiters, type) %} |
Comment on c7a7ee4, file templates/macros.jinja2, line 28. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpo9b7vard/templates/macros.jinja2
+++ b/tmp/tmpo9b7vard/templates/macros.jinja2
@@ -25,7 +25,7 @@
<tt>{{ item.end | escape }}</tt>
{% else %}
(EOL)
- {% endif %}
+ {% endif %}{# if item.end #}
</li>
{% endif %}
{% endfor %} |
Comment on c7a7ee4, file templates/macros.jinja2, line 30. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpo9b7vard/templates/macros.jinja2
+++ b/tmp/tmpo9b7vard/templates/macros.jinja2
@@ -27,7 +27,7 @@
(EOL)
{% endif %}
</li>
- {% endif %}
+ {% endif %}{# if item.type == type #}
{% endfor %}
</ul>
{% endmacro %} |
Comment on c7a7ee4, file templates/macros.jinja2, line 31. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpo9b7vard/templates/macros.jinja2
+++ b/tmp/tmpo9b7vard/templates/macros.jinja2
@@ -28,6 +28,6 @@
{% endif %}
</li>
{% endif %}
- {% endfor %}
+ {% endfor %}{# for item in delimiters #}
</ul>
{% endmacro %} |
Comment on c7a7ee4, file templates/home.html.jinja2, line 16. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpo9b7vard/templates/home.html.jinja2
+++ b/tmp/tmpo9b7vard/templates/home.html.jinja2
@@ -13,7 +13,7 @@
<ul class="thin-row-medium" id="languages-list">
{% for language in languages %}
<li><a href="{% url 'languages', language %}">{{ m.language_name(language) }}</a>
- {% endfor %}
+ {% endfor %}{# for language in languages #}
</ul>
</body>
</html> |
c7a7ee4
to
da8c4cb
Compare
Comment on da8c4cb, file templates/home.html.jinja2, line 16. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmplz2jz9lw/templates/home.html.jinja2
+++ b/tmp/tmplz2jz9lw/templates/home.html.jinja2
@@ -13,7 +13,7 @@
<ul class="thin-row-medium" id="languages-list">
{% for language in languages %}
<li><a href="{% url 'languages', language %}">{{ m.language_name(language) }}</a>
- {% endfor %}
+ {% endfor %}{# for language in languages #}
</ul>
</body>
</html> |
Comment on da8c4cb, file templates/Language.html.jinja2, line 17. Variable blocks should be spaced with Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmplz2jz9lw/templates/Language.html.jinja2
+++ b/tmp/tmplz2jz9lw/templates/Language.html.jinja2
@@ -14,7 +14,7 @@
<tr>
<th>Grammar File</th>
<td>
- <a href = {{language.grammar_file}}>
+ <a href = {{ language.grammar_file }}>
{{ m.show_grammar(language.grammar_file) }}
</a>
</td> |
Comment on da8c4cb, file templates/macros.jinja2, line 6. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmplz2jz9lw/templates/macros.jinja2
+++ b/tmp/tmplz2jz9lw/templates/macros.jinja2
@@ -3,7 +3,7 @@
{{ language.full_name }}
{% else %}
{{ language.identifier }}
-{% endif %}
+{% endif %}{# if language.full_name #}
{% endmacro %}
{% macro show_grammar(grammar_file) %} |
Comment on da8c4cb, file templates/macros.jinja2, line 10. Variable blocks should be spaced with Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmplz2jz9lw/templates/macros.jinja2
+++ b/tmp/tmplz2jz9lw/templates/macros.jinja2
@@ -7,7 +7,7 @@
{% endmacro %}
{% macro show_grammar(grammar_file) %}
- {{grammar_file}}
+ {{ grammar_file }}
{% endmacro %}
{% macro show_list(list, separator=',') %} |
Comment on da8c4cb, file templates/macros.jinja2, line 15. Variable blocks should be spaced with Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmplz2jz9lw/templates/macros.jinja2
+++ b/tmp/tmplz2jz9lw/templates/macros.jinja2
@@ -12,7 +12,7 @@
{% macro show_list(list, separator=',') %}
{% for item in list %}
- {{ item.pk | escape }}{% if not loop.last %}{{separator}} {% endif %}
+ {{ item.pk | escape }}{% if not loop.last %}{{ separator }} {% endif %}
{% endfor %}
{% endmacro %}
|
Comment on da8c4cb, file templates/macros.jinja2, line 16. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmplz2jz9lw/templates/macros.jinja2
+++ b/tmp/tmplz2jz9lw/templates/macros.jinja2
@@ -13,7 +13,7 @@
{% macro show_list(list, separator=',') %}
{% for item in list %}
{{ item.pk | escape }}{% if not loop.last %}{{separator}} {% endif %}
- {% endfor %}
+ {% endfor %}{# for item in list #}
{% endmacro %}
{% macro show_delimiter_list(delimiters, type) %} |
Comment on da8c4cb, file templates/macros.jinja2, line 28. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmplz2jz9lw/templates/macros.jinja2
+++ b/tmp/tmplz2jz9lw/templates/macros.jinja2
@@ -25,7 +25,7 @@
<tt>{{ item.end | escape }}</tt>
{% else %}
(EOL)
- {% endif %}
+ {% endif %}{# if item.end #}
</li>
{% endif %}
{% endfor %} |
Comment on da8c4cb, file templates/macros.jinja2, line 30. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmplz2jz9lw/templates/macros.jinja2
+++ b/tmp/tmplz2jz9lw/templates/macros.jinja2
@@ -27,7 +27,7 @@
(EOL)
{% endif %}
</li>
- {% endif %}
+ {% endif %}{# if item.type == type #}
{% endfor %}
</ul>
{% endmacro %} |
Comment on da8c4cb, file templates/macros.jinja2, line 31. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmplz2jz9lw/templates/macros.jinja2
+++ b/tmp/tmplz2jz9lw/templates/macros.jinja2
@@ -28,6 +28,6 @@
{% endif %}
</li>
{% endif %}
- {% endfor %}
+ {% endfor %}{# for item in delimiters #}
</ul>
{% endmacro %} |
da8c4cb
to
3eb6313
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
CI is showing you a lot of errors, which is expected. 😉
Since you add rules in .coafile
, CI is more powerful and it is able to detect errors using the bears you introduced. You need to fix those errors.
Comment on 3eb6313, file templates/Language.html.jinja2, line 17. Variable blocks should be spaced with Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpn_oayuko/templates/Language.html.jinja2
+++ b/tmp/tmpn_oayuko/templates/Language.html.jinja2
@@ -14,7 +14,7 @@
<tr>
<th>Grammar File</th>
<td>
- <a href = {{language.grammar_file}}>
+ <a href = {{ language.grammar_file }}>
{{ m.show_grammar(language.grammar_file) }}
</a>
</td> |
Comment on 3eb6313, file templates/macros.jinja2, line 6. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpn_oayuko/templates/macros.jinja2
+++ b/tmp/tmpn_oayuko/templates/macros.jinja2
@@ -3,7 +3,7 @@
{{ language.full_name }}
{% else %}
{{ language.identifier }}
-{% endif %}
+{% endif %}{# if language.full_name #}
{% endmacro %}
{% macro show_grammar(grammar_file) %} |
Comment on 3eb6313, file templates/macros.jinja2, line 16. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpn_oayuko/templates/macros.jinja2
+++ b/tmp/tmpn_oayuko/templates/macros.jinja2
@@ -13,7 +13,7 @@
{% macro show_list(list, separator=',') %}
{% for item in list %}
{{ item.pk | escape }}{% if not loop.last %}{{separator}} {% endif %}
- {% endfor %}
+ {% endfor %}{# for item in list #}
{% endmacro %}
{% macro show_delimiter_list(delimiters, type) %} |
Comment on 3eb6313, file templates/macros.jinja2, line 28. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpn_oayuko/templates/macros.jinja2
+++ b/tmp/tmpn_oayuko/templates/macros.jinja2
@@ -25,7 +25,7 @@
<tt>{{ item.end | escape }}</tt>
{% else %}
(EOL)
- {% endif %}
+ {% endif %}{# if item.end #}
</li>
{% endif %}
{% endfor %} |
Comment on 3eb6313, file templates/macros.jinja2, line 30. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpn_oayuko/templates/macros.jinja2
+++ b/tmp/tmpn_oayuko/templates/macros.jinja2
@@ -27,7 +27,7 @@
(EOL)
{% endif %}
</li>
- {% endif %}
+ {% endif %}{# if item.type == type #}
{% endfor %}
</ul>
{% endmacro %} |
Comment on 3eb6313, file templates/macros.jinja2, line 31. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpn_oayuko/templates/macros.jinja2
+++ b/tmp/tmpn_oayuko/templates/macros.jinja2
@@ -28,6 +28,6 @@
{% endif %}
</li>
{% endif %}
- {% endfor %}
+ {% endfor %}{# for item in delimiters #}
</ul>
{% endmacro %} |
Comment on 3eb6313, file templates/home.html.jinja2, line 16. Unlabeled control end tag Origin: Jinja2Bear, Section: The issue can be fixed by applying the following patch: --- a/tmp/tmpn_oayuko/templates/home.html.jinja2
+++ b/tmp/tmpn_oayuko/templates/home.html.jinja2
@@ -13,7 +13,7 @@
<ul class="thin-row-medium" id="languages-list">
{% for language in languages %}
<li><a href="{% url 'languages', language %}">{{ m.language_name(language) }}</a>
- {% endfor %}
+ {% endfor %}{# for language in languages #}
</ul>
</body>
</html> |
3eb6313
to
be07671
Compare
be07671
to
313a5f8
Compare
.coafile
Outdated
@@ -0,0 +1,16 @@ | |||
[Default] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
an empty Default is useless, and Default
is deprecated anyway ... just remove
.coafile
Outdated
[Default] | ||
|
||
[autopep8] | ||
bears = PEP8Bear, PycodestyleBear |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
these are python bears, and there is no python files in this repo
.coafile
Outdated
|
||
[jinja2] | ||
bears = Jinja2Bear | ||
files = **.jinja2, **.jj2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there are no .jj2 files in this repo
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I saw there were jj2 files on other repos and I thought that those kind of files could be included here in the future as well.
.coafile
Outdated
|
||
[yaml] | ||
bears = YAMLLintBear | ||
files = *.yml, **/*.yaml |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
**.yaml
does the same thing
data/Language/TinyBasic.yaml
Outdated
@@ -1,7 +1,8 @@ | |||
identifier: TinyBasic | |||
full_name: TinyBasic | |||
wikidata: Q586622 | |||
grammar_file: https://github.com/antlr/grammars-v4/tree/master/tinybasic/tinybasic.g4 | |||
grammar_file: https://github.com/antlr/grammars-v4/tree/master/tinybasic | |||
/tinybasic.g4 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in other cases you leave the /
on the previous line. here it is different. please be consistent.
This entrypoint adds a .coafile for .yaml and .jinja2 files. Closes coala#33
313a5f8
to
923609d
Compare
ack 923609d |
@gitmate-bot ff |
Hey! I'm GitMate.io! This pull request is being fastforwarded automatically. Please DO NOT push while fastforward is in progress or your changes would be lost permanently |
Automated fastforward with GitMate.io was successful! 🎉 |
This entrypoint adds a .coafile for .yaml
and .jinja2 files.
Closes #33