atuttle / atom-language-cfml

:space_invader: A CFML Language for the Atom Editor
38 stars 24 forks source link

Adding addition file extention #102

Closed jmohler1970 closed 7 years ago

jmohler1970 commented 7 years ago

I regularly have ColdFusion files with a *.cfi name.

I do this for files that must only be used as an include and never directly ran.

Is there a way to have syntax highlighting for that extension?

jmohler1970 commented 7 years ago

Just found it:

lib/languageCFML.js on line 32 needs to read:

} else if (editor.getURI().endsWith("cfm") || editor.getURI().endsWith("cfml") || editor.getURI().endsWith("cfi")) {
atuttle commented 7 years ago

Is this a standard practice? First I've ever heard of it.

KamasamaK commented 7 years ago

I don't believe that is standard practice. You can edit your config.cson (File > Config...) like so to accomplish your recommended change:

core:
  customFileTypes:
    'text.html.cfml': [
      'cfi'
    ]
David-Polehonski commented 7 years ago

I would agree with @KamasamaK this would be a local configuration rather than a plugin update. Shall we mark this issue as closed?

atuttle commented 7 years ago

Sounds like the right solution to me.

jmohler1970 commented 7 years ago

Good for me