[Catalyst] Re: Patch for Catalyst::View::Mason
Aristotle Pagaltzis
pagaltzis at gmx.de
Sun Mar 9 12:43:04 GMT 2008
* Sebastian Willert <willert at gmail.com> [2008-03-08 19:50]:
> On Sat, 2008-03-08 at 07:26 +0100, Aristotle Pagaltzis wrote:
> > * Christopher H. Laco <claco at chrislaco.com> [2008-03-07 22:25]:
> > > I go one stranger. No extensions ever. Instead, I rely on
> > > directories assuming I might switch.
> > >
> > > templates/tt/controller/action
> > > templates/mason/controller/action
> >
> > That’s the best approach.
> >
> > The only reason I don’t do it that way is syntax highlighting.
> > Though I suppose I could litter all my files with modelines…
>
> Guessing you are on Emacs
No Emacs here – I use vim.
> you could simply put those lines in your config
D’uh! I should have thought of that approach.
> ;; mmm-mode for mason
> (require 'mmm-auto)
> (autoload 'html-mode "xml-html-mode" "Load html-mode" t)
> (setq auto-mode-alist (cons '("\\/templates/mason/" 'xml-html-mode)
> auto-mode-alist))
> (mmm-add-mode-ext-class nil "\\/templates/mason/" 'mason )
I see your bid and raise this:
autocmd BufRead */templates/tt/* set ft=tt2html
autocmd BufRead */templates/mason/* set ft=mason
Wheee.
* Jonathan Rockway <jon at jrock.us> [2008-03-09 01:20]:
> I'm pretty sure Aristotle uses vi, though ;)
Real vi doesn’t do syntax highlighting. ;)
Regards,
--
Aristotle Pagaltzis // <http://plasmasturm.org/>
More information about the Catalyst
mailing list