Sublime Forum

Vintage plugin: switch to command mode on save

#1

Hi,

Maybe this is already possible, if so, please tell me.

My idea: If Sublime Text 2 entered command mode on save it would be more like “real” Vim.

0 Likes

Nightly Build 2191
#2

This plugin should do the trick:

import sublime, sublime_plugin

class GoToCommandModeOnSaveCommand(sublime_plugin.EventListener):
	def on_post_save(self, view):
		view.run_command("exit_insert_mode")

Save as “GoToCommandModeOnSave.py” and place in your /Packages/User/ folder, it should start working immediately.

0 Likes

#3

Thanks!

0 Likes