예제 #1
0
def editor(path, line, column, command):
    """Execute user request."""

    with open(ROOT + path) as f:
        lines = f.readlines()
        source = ''.join(lines)

    request = {
        'command': command,
        'attributes': {
            'source': source,
            'line': line,
            'column': column,
            'path': path,
        }
    }

    return anaconda.process(**request)