The file you are editing needs the correct extension ( .rb in your case) so that Textmate understands the correct package to use.
What do you see at the bottom of your TM window? (After row # and column #)?
Is this "Plain Text" ?
If you see something other than Ruby or Ruby on Rails , click on the small up / down arrows to the right of it to open the drop-down list of bundles and select: Ruby or Ruby on Rails .
That way, when you press TAB after writing " def " , it will automatically finish creating the method for you.
You can also check Bundles> Bundle editor> Edit snippets ... (then select Ruby) to find out if you have a βdefβ fragment that was triggered when you pressed TAB (see Declaration> Methods) .
source share