MCPcopy Create free account
hub / github.com/chasingboy/Xtools / SortAndUniqueTextCommand

Class SortAndUniqueTextCommand

xtools.py:319–324  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

317
318
319class SortAndUniqueTextCommand(sublime_plugin.TextCommand):
320 def run(self, edit):
321 text = get_buffer_text(self.view)
322 text = list(set(text.split('\n')))
323 text = '\n'.join(sorted(text))
324 update_file(self.view, edit, text)
325
326
327# Text encode

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected