Created
June 12, 2013 21:47
-
-
Save jacob-ogre/5769419 to your computer and use it in GitHub Desktop.
Close the pseudo-NerdTree and return focus in Sublime Text 2
This file contains hidden or 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
import sublime, sublime_plugin | |
class NerdTreeCloseCommand(sublime_plugin.WindowCommand): | |
def run(self): | |
self.window.run_command("focus_group", {"group": 0} ) | |
self.window.run_command("toggle_side_bar") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I use 'nt' in Vim to toggle NerdTree; in ST2, to avoid any conflict, use 'nt' to open and 'tn' to close the sidebar (and return focus to group 0).