I wrote a sublime text 2 plugin: generate_uuid

I'm not going to try to publish it to package control, but it saved me a load of time when editing a file the other day.

# Sublime Text 2 Plugin to generate a UUID in place.
# I used this to build out a sample data file with dependable UUID's for testing purposes.
import sublime, sublime_plugin, uuid
class GenerateUuidCommand(sublime_plugin.TextCommand):
def run(self, edit):
for s in self.view.sel():
if s.empty():
self.view.insert(edit, s.b, str(uuid.uuid4())
view raw GenerateUUID.py hosted with ❤ by GitHub

Comments