Forked from daftspunk/ConvertTwoSpacesToFour.sublime-macro
Created
September 14, 2016 19:27
-
-
Save tannerhodges/30b178dfc3f4d7cf5324f8ff3b0f4dc1 to your computer and use it in GitHub Desktop.
Convert 4 spaces to 2 spaces, Sublime Text macro
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
// | |
// Converts code indentation from 4 spaces to 2 spaces | |
// | |
// For a hotkey, add to Preferences > Key Bindings - User: | |
// | |
// { "keys": ["ctrl+alt+i"], "command": "run_macro_file", "args": {"file": "res://Packages/User/ConvertTwoSpacesToFour.sublime-macro"} } | |
// | |
[ | |
{ | |
"args": { "setting": "tab_size", "value": 4 }, | |
"command": "set_setting" | |
}, | |
{ | |
"args": { "set_translate_tabs": true }, | |
"command": "unexpand_tabs" | |
}, | |
{ | |
"args": { "setting": "tab_size", "value": 2 }, | |
"command": "set_setting" | |
}, | |
{ | |
"args": { "set_translate_tabs": true }, | |
"command": "expand_tabs" | |
} | |
] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment