User Tools

Site Tools


ultraedit

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
Next revisionBoth sides next revision
ultraedit [2014/10/03 09:32] – created dblumeultraedit [2014/10/09 17:03] – [Code on Linux Boxes] dblume
Line 44: Line 44:
 if __name__ == '__main__': if __name__ == '__main__':
     params = [win2nix(i) for i in sys.argv[1:]]     params = [win2nix(i) for i in sys.argv[1:]]
 +    # Note: commands like "cd" would require "shell=true"
     r = check_output(params)     r = check_output(params)
     nix2win(r)     nix2win(r)
Line 101: Line 102:
         // UltraEdit.outputWindow.write("DCB: Going to process file_to_open " + file_to_open + " at line " + line_number);         // UltraEdit.outputWindow.write("DCB: Going to process file_to_open " + file_to_open + " at line " + line_number);
          
-        if (file_to_open.length > 0) {  // Is there a header or source file for the active file? +        if (file_to_open.length > 0) { 
-         +            for (var doc_index = 0; doc_index < UltraEdit.document.length; doc_index++) {
-            var doc_index = 0; // Look if this file is already open. +
-            do {+
                 open_filename = UltraEdit.document[doc_index].path.toLowerCase();                 open_filename = UltraEdit.document[doc_index].path.toLowerCase();
                 if (open_filename == lowercase_file_to_open) {                 if (open_filename == lowercase_file_to_open) {
Line 110: Line 109:
                     break;                     break;
                 }                 }
-            } while (++doc_index < UltraEdit.document.length) +            } 
-             + 
-            if (doc_index >= UltraEdit.document.length)+            if (doc_index >= UltraEdit.document.length) 
 +                UltraEdit.outputWindow.write("DCB: used open().");
                 UltraEdit.open(file_to_open);                 UltraEdit.open(file_to_open);
 +            }
                          
             UltraEdit.activeDocument.gotoLine(line_number,0);             UltraEdit.activeDocument.gotoLine(line_number,0);