def get_version():
    version = ''
    with open('grimreaper.py', 'r') as fd:
        version = re.search(r'^__version__\s*=\s*[\'"]([^\'"]*)[\'"]',
                            fd.read(), re.MULTILINE).group(1)

    if not version:
        raise RuntimeError("Cannot find version's information")
    return version