import sublime
import sublime_plugin
import os


class ExPrintWorkingDir(sublime_plugin.TextCommand):
    def run(self, edit):
        sublime.status_message(os.getcwd())


class ExWriteFile(sublime_plugin.TextCommand):
    def run(self, edit):
        self.view.run_command('save')


class ExWriteAll(sublime_plugin.TextCommand):
    def run(self, edit):
        for v in self.view.window().views():
            v.run_command('save')

@@ -227,34 +227,369 @@
 f run(self, edit
-):
+, file_name='', range=None, **kwargs):%0A        if file_name and file_name != os.path.basename(self.view.file_name()):%0A            v = self.view.window().new_file()%0A            v.set_name(file_name)%0A            return%0A        %0A        if range:%0A            sublime.status_message('VintageEx: Command not implemented.')%0A            return%0A
 %0A        self.vi

Improve ExWriteFile command.