Logo Search packages:      
Sourcecode: zope-externaleditor version File versions  Download package

def ExternalEditor::zopeedit::EditorProcess::__init__ (   self,
  command 
)
Launch editor process

Definition at line 645 of file zopeedit.py.

                                   :
            """Launch editor process"""
            # Prepare the command arguments, we use this regex to 
            # split on whitespace and properly handle quoting
            arg_re = r"""\s*([^'"]\S+)\s+|\s*"([^"]+)"\s*|\s*'([^']+)'\s*"""
            args = re.split(arg_re, command.strip())
            args = filter(None, args) # Remove empty elements
            self.pid = os.spawnvp(os.P_NOWAIT, args[0], args)
        

Generated by  Doxygen 1.6.0   Back to index