Book Image

TextMate How-To

By : Christopher J Mears
Book Image

TextMate How-To

By: Christopher J Mears

Overview of this book

Not all text editors are created equal. TextMate was created with versatility and power to the developer. Whether you want to organize your files in projects, utilize the efficiency of code completion, take advantage of the thousands of publicly available bundles, or gain insight using powerful regular expression searching, TextMate is an essential and easy-to-use tool you need in your development arsenal. "TextMate How-To" is a practical guide filled with conventional recipes on using one of the most popular text editors on the OS X platform. It is a great resource for anyone who wants to learn how to code more efficiently and effectively, no matter what programming or scripting language you use. This book will guide the reader through using TextMate for practical purposes. It will start with configuring the application, then cover navigation and editing of files, and finish with bundles and advanced features. Throughout the book, the reader will quickly master the key features of the application through easy to follow tasks. Using this book, the reader will learn the most common text editing and coding tasks including navigation through the document and searching of text. The reader will then learn about working with and navigating between files and projects as well as utilizing bundles to greatly speed up development. Finally, explore the ability to use shell commands and macros to increase productivity. With just a few hours, "TextMate How-To" will teach the reader everything necessary to hit the ground running with this powerful text editor.
Table of Contents (7 chapters)

Bookmarking (Should know)


Bookmarking is a great way to save a line of code so that you can navigate back to it later or cycle among all of your bookmarks.

How to do it...

You can use the following methods to bookmark a line:

  • From the menu, select Navigation | Add Bookmark and Navigation | Remove Bookmark.

  • The keyboard shortcut Command + F2

  • Click on the gutter next to the line in order to toggle the bookmark:

How it works...

A star indicator in the gutter signifies when a line has been bookmarked.

  • The Next Bookmark option is used to go to the next bookmark in the document. From the menu, select Navigation | Next Bookmark (F2).

  • The Previous Bookmark option is used to go the previous bookmark in the document. From the menu, select Navigation | Previous Bookmark (Shift + F2).