TypoFixr
Auto correct your code typos in Sublime Text
Details
Installs
- Total 965
- Win 510
- Mac 306
- Linux 149
| Mar 12 | Mar 11 | Mar 10 | Mar 9 | Mar 8 | Mar 7 | Mar 6 | Mar 5 | Mar 4 | Mar 3 | Mar 2 | Mar 1 | Feb 28 | Feb 27 | Feb 26 | Feb 25 | Feb 24 | Feb 23 | Feb 22 | Feb 21 | Feb 20 | Feb 19 | Feb 18 | Feb 17 | Feb 16 | Feb 15 | Feb 14 | Feb 13 | Feb 12 | Feb 11 | Feb 10 | Feb 9 | Feb 8 | Feb 7 | Feb 6 | Feb 5 | Feb 4 | Feb 3 | Feb 2 | Feb 1 | Jan 31 | Jan 30 | Jan 29 | Jan 28 | Jan 27 | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Windows | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| Mac | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| Linux | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
Readme
- Source
- raw.githubusercontent.com
TypoFixr
A Sublime Text plugin that allows you to…
determine a list of possible typos and correct them automatically
Intro
Are you tired of seeing :
wnidow is not defined
or
dispaly is not defined
while coding Javascript ?
TypoFixr gets you covered. Define your own list of possible typos, and correct them on-save or manually.
Installation
It is available through Sublime Package Contol and this is the recommended way of installation. Just open Packaopge Control and look for TypoFirx
Alternative installation methods
From github
You can install from github if you want, although Package Control automates
just that. Go to your Packages subdirectory under ST's data directory:
- Windows:
%APPDATA%\Sublime Text X - OS X:
~/Library/Application Support/Sublime Text X - Linux:
~/.config/sublime-text-X - Portable Installation:
Sublime Text X/Data
Then clone this repository:
git clone git://github.com/sylzys/TypoFixr.git
Manually
Download the plugin as a zip. Copy the TypoFixr directory to its location (see prior section).
Usage
Correction
- bind the deletion command to a keyboard shortcut:
To add a key binding, open “Preferences / Key Bindings - User” and add:
{ "keys": ["ctrl+shift+c"], "cwindow": "typofixr" }
With this setting, pressing Ctrl + Shift + c will list the typos you defined (see settings) and correct them with the corresponding word of your choise throughout the current file! For OSX users, quoting wbond: “When porting a key binding across OSes, it is common for the ctrl key on Windows and Linux to be swapped out for super on OS X” (eg. use “super+ctrl+c” instead).
Beware: the binding from this example may override one of the default ST's mapping, or one of your own defined mapping. You can look at the default bindings in “Preferences / Key Bindings - Default”, or at user's binding in “Preferences / Key Bindings - User”.
Settings
For the plugin to work, you first have to set your own list of typos and their replacements. Settings are stored in a configuration file, as JSON. You must use a specific file: Go to “Preferences / Package Settings / TypoFixr / Settings - User” to add you custom settings. You can look at the default values in “Settings - Default”, in the same menu.
Turning the correction on save on / off
Default: “true”
You may turn auto correction on file save ON / OFF. The auto correct doesn't take place while in the settings file, to prevent correction of the typos you just defined.
{ "execute_on_save": true, }
Defining your own typo list
You can define your own list of typos. Just use the “replacements” settings, with the typo on the left side, and the corresponding correction on the right side.
{ "replacements": {
"wnidow" : "window",
[...]
"dcoument": "document"
}
}