Sublime text features for general text editing

Jul 27, 2020
For years i have been using Sublime text which is one of the best IDE's out there for programmers to write code. Although majority of the people use it for writing code, for me its been a great tool for general text editing as well as writing code.

What can sublime do?

For years i have been using Sublime text which is one of the best IDE's out there for programmers to write code. Although majority of the people use it for writing code, for me its been a great tool for general text editing as well as writing code. It is quick and can handle large text files for you with ease. Lets look at some of these useful text editing features. If you're a programmer you've already probably used Sublime text or VS Code and are familiar with the features for coding. In this article we'll look at some general text manipulation features.

Features I use the most

To start with let me give you some examples of how powerful Sublime text is as a general text editor. In this section we'll look at some of the built in features that are available for text manipulation.

Built in features

sort-and-remove-duplicate

Command Palette

The command palette can be used to quickly search for a command and use it.

Sort Lines

As the name suggests, this command exactly does that. It allows you to sort lines alphabetically. Very useful when working with lists and i use this feature a lot with highlight duplicates command.

Multiple selections

This feature is quite powerful, it allows you to select a particular pattern that occours on multiple lines in your file. Selecting a pattern and hitting ctrl + command + g will select all occourences of the match. You can then do whatever with the selected text.

Next Occurrence

This feature is similar to the multiple selection but this only selects one instance of the occurence at once. You can navigate through and manipulate the selected text the way you want.

To Upper / Lower

This is a simple but useful feature. This could be used in combination with the multiple selection and next occurrence feature to select multiple instances and chenging their cases.

Vertical selection

I love this feature. At first it might look like not so useful, but when there is a use case for this its easily the most powerful feature. Again when combined with multiple selection it can save you a ton of time.

Move current line up

A simple command to move a line up. Placing the cursor on a line you want to move up and hitting `shift + command + up` will move the line up. It is useful when workign with lists you want to order.

Move current line down

Similar command to move a line down. Placing the cursor on a line you want to move down and hitting `shift + command + down` will move the line down. It is useful when workign with lists you want to order.

Duplicate selected content

I find myself using this command a lot. Its useful when coding, specially working on the front end like HTML where you copy sections or links or whatever over and over again. This also helps with general text editing where you might want to copy headings often and just change the text.

Plugins

Lets look at a few text editing plugins that can save you a lot of time.

Text Pastry

This plugins offers a wide range of text helpers if you like. Some helpers such as "filter selection, range, add / reduce selection, pipe into selection, from 0 to X, 1 to X" etc. are great when needed. To see how to use these commands and when to use, please visit the plugins page.

Highlight Duplicates

Handy when working with lists. This command allows you to toggle, select and remove duplicates from a file. I use this when I have a list of names or company names and i want to check for any duplicates and remove them. The toggle feature nicely highlights duplicates so you can visually see the duplicate entries and remove accordingly. This feature works well with "Sort lines" to sort alphabetically and then remove duplicates.

Google spell check

Very simple but powerful plugin that does a soogle spell check automatically and auto correct.

Lorem ipsum dolor sit amet

A fun plugin that can be used to generate some dummy text to fill in paragraphs with some text. Its useful when building a static website where you would want to add some dummy content to see how the page looks.

Closing

There are a ton of plugins to help you with you daily tasks. Although some of these features could be done via a regular text editor such as word or word pad, excel etc. Sublime is easily 10x faster than your regular tool. It can open and index huge files with ease and once indexed, text manipulation becomes a bliss. I've used sublime to search / replace patterns and manipulate text on csv files that are as big as 4GB. Having used other editors like VS Code, Atom etc. Sublime text by far is the fastest i've come across. What is better than giving it a go and finding out for oueselves? So give it a go if some of these features interests you.

Sublime text is free and includes all the feature, however a popup keeps coming up asking you to purchase a lisence. It is upto you if you want to purchase a copy and help the developers come up with more awesome features. You can download here.