[Turn off line numbering]1: arg dict, line; 2: var cmd; 3: 4: if (!line) { 5: // we have to do this as such, because of logic (shrug) 6: dict = dict.add('status, 'not_done); 7: return dict.add_elem('lines, line); 8: } else if (line[1] == ".") { 9: if (line.length() > 1 && line[2] == ".") 10: line = line.subrange(2); 11: else if (line.length() == 1) 12: return dict.add('status, 'done); 13: 14: //// No, bad Brandon, Bad, no scooby snack 15: //// Decomment this if you want '>' to escape commands when reading 16: // } else if (line[1] == ">") { 17: // if (line.length() > 1 && line[2] == ">") { 18: // line = line.subrange(2); 19: // } else { 20: // dict = dict.add('command, line.subrange(2)); 21: // return dict.add('status, 'pass_command); 22: // } 23: } else if (line == "@abort") { 24: return dict.add('status, 'abort); 25: } 26: dict = dict.add('status, 'not_done); 27: return dict.add_elem('lines, line);
// Created 27-Mar-1995 as a part of ColdCore, see: @help Credit