Search for

Comment and Uncomment Code Quickly in Coda

Comments are great for making sense of code, they’re also really handy for debugging. By “commenting out” code you can prevent it from being from run without having to delete it.

Doing this for a single line is easy peasy just stick you cursor at the begining of the line and tap / twice.
doSomething();
becomes
// doSomething();

However commenting out multiple lines is a bit more of a pain: click at the beginning,insert /*, click at the end insert */.

Recent I discovered a way to do this really quickly in Coda, just select the code you want to comment out, hold down cmd and press /. You can also go the other way, just make sure you selection starts at the /* and ends at the /* and it will remove the comment for you.

*required

*required (will not be published)

Allowed html: <a href="">, <b>, <strong>, <em>, <i>, <strike>, <code> and <blockquote>

Archives

Copyright © 2010 - Greg Johnson