Andrew Otwell
2005-06-07 02:46:15 UTC
I've made a Ruby & Rails syntax coloring module for BBEdit. This is a
"Codeless Language Module", so it will only work with BBEdit 8+. It's
basically a giant list of Ruby and Rails keywords, method names, and
so on. It's both Ruby and Rails because BBedit only lets you
associate a file type with one language module.
The file is available here:
http://www.heyotwell.com/work/misc/Ruby.plist (42k plist file)
To use it, just drop it into ~/Library/Application Support/BBEdit/
Language Modules and restart BBEdit.
Note: If you're already using the old Ruby plugin BareBones provides
a link to on their site, you'll have to get rid of it; again, only
one language definition can be associated with Ruby files. I find
that that plugin (from 2001), is badly out of date and does a
terrible job coloring Ruby syntax anyway...it can't even color
comments properly.
Also note: there's one big known issue with Codeless Language
Modules: BBEdit isn't smart enough to parse Ruby-style functions,
especially those with if/else/end clauses. So, some functions don't
correctly get added to BBEdit's function pop-up. (Workaround: stop
writing functions with if/else/end clauses!) Please ask BareBones to
add better support for Ruby-style function definitions in CLMs!
Any improvements or additions would be great. I'll try to keep this
up-to-date with new versions of Rails.
Best,
Andrew
"Codeless Language Module", so it will only work with BBEdit 8+. It's
basically a giant list of Ruby and Rails keywords, method names, and
so on. It's both Ruby and Rails because BBedit only lets you
associate a file type with one language module.
The file is available here:
http://www.heyotwell.com/work/misc/Ruby.plist (42k plist file)
To use it, just drop it into ~/Library/Application Support/BBEdit/
Language Modules and restart BBEdit.
Note: If you're already using the old Ruby plugin BareBones provides
a link to on their site, you'll have to get rid of it; again, only
one language definition can be associated with Ruby files. I find
that that plugin (from 2001), is badly out of date and does a
terrible job coloring Ruby syntax anyway...it can't even color
comments properly.
Also note: there's one big known issue with Codeless Language
Modules: BBEdit isn't smart enough to parse Ruby-style functions,
especially those with if/else/end clauses. So, some functions don't
correctly get added to BBEdit's function pop-up. (Workaround: stop
writing functions with if/else/end clauses!) Please ask BareBones to
add better support for Ruby-style function definitions in CLMs!
Any improvements or additions would be great. I'll try to keep this
up-to-date with new versions of Rails.
Best,
Andrew