-
-
Notifications
You must be signed in to change notification settings - Fork 24
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
File association #4
Comments
does this work for php code, ie. if you open a *.html file with the PHP Editor - do you get PHP syntax highlighting? I've added the html extension to the TwigStructuredEditor, but somehow it's still not using the TwigEditor. Same happens for PHP syntax if i open an *.html file with the php editor. |
Yes, same behavior |
This is how you can make the Twig editor recognizy any file extension you wish as twig content-type:
|
I'm atempting the same, but it won't use the twig syntax highlighting. I set *.html for twig template under content types. I use the 'open with -> twig editor' method, still it won't work! The same problem exists for PHP editor or smarty templates There seems to be something wrong with eclipse ignoring the File Association or the custom choice with 'open with' and just going for whatever it feels should be the default |
Okay I've been trying different stuff and the behavory is really weird. I also installed http://eclipse.kacprzak.org/ since the django editor is almost the same as twig and it's working properly but nonetheless the behavory stays odd! I created an imaginary file extension .ben Now I try to open the file with 'open with' and I get the following results: The default is set to Smarty Editor at this point so it's completely ignoring that ... I don't get it, I just know it's messed up and if I can't even set it right for .ben then I'm definitely not going to get it right for .html ... |
tested with clean install of indigo and juno, both are showing the same problem :( |
Manually adding the TwigNature does the trick |
what do you mean with TwigNature ? |
trying to add *.html extension to work with twig highlighting. but it isn't working, even if open with twig editor. added here "Under Text -> PHP Content Type -> Twig Template" any advice? |
Hello, Regards, |
We are using in project *.html files, I associated them with twig editor, but document still not recognized as Twig template
I noticed that there is a check for extenion can cause this problem
src / org / eclipse / twig / ui / editor / TwigStructuredEditor.java
if ("twig".equals(resource.getFullPath().getFileExtension())) {
TwigSourceParser.editFile.set(resource);
super.doSetInput(input);
} else {
super.doSetInput(input);
}
The text was updated successfully, but these errors were encountered: