How do I tweak grammar rules for a custom file type?


How do I add a new, custom file type and have it recognised by Atom?

I’m not looking to associate a custom file type with a known grammar (as in the discussion here – rather I would like to add a custom file type (save, and then disable certain rules for that file type inside my config.cson, for example:

“”: [
ensureSingleTrailingNewline: false
removeTrailingWhitespace: true


You want to make a new grammar, in order to identify your files as belonging to it and give it its own config settings. The grammar doesn’t have to have anything in patterns to do what you want.