-
Notifications
You must be signed in to change notification settings - Fork 996
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
Extra syntax conflict #1309
Comments
Looks like the extra -> default syntax fallback is not working well |
@tatref what do you think of this patch instead? I think the logical error was there: when there are some extra syntaxes, only those were looked up, not the theme. |
unrelated, but there seems to be some hardcoded |
Yes, your patch is semantically more correct. Something else related to highlighting: what do you think about emitting warnings is the language is not found? (so if fallback to plaintext) |
Ok i opened #1312 with such warnings. What do you think?
My bad it looks OK actually :) |
Was able to checkout and build the edit: |
Needed to add syntaxes to syntaxes/ because apparently using extra_syntaxes results in the default syntaxes not working anymore: getzola/zola#1309
Needed to add syntaxes to syntaxes/ because apparently using extra_syntaxes results in the default syntaxes not working anymore: getzola/zola#1309
Defining `extra_syntaxes` in the config causes default syntaxes to stop working, see getzola/zola#1309. Fixed temporarily by copying in the syntax files I use, will revert on a new release from Zola.
@tomholford see #1529 |
Bug Report
When defining
extra_syntaxes
inconfig.toml
, standard highlighters no longer work.Environment
Zola version: 0.13, also tested master and next branches (2021-01-14).
This was working with the next branch some days ago (not sure about the exact date though..)
Step to reproduce
Test article.
py3
is a standard language.shell-session
is a custom language, defined insyntaxes/shell-session.sublime-syntax
1st test case: here I set
extra_syntaxes
in cargo.toml:Result:
Note that the python code is node highlighted, that's the issue
2nd test case:
extra_syntaxes
is commented:The python code is now properly highlighted.
If you want to reproduce, here is the
shell-session.sublime-syntax
(disclaimer: it's just a quick and dirty hack...)The text was updated successfully, but these errors were encountered: