Read the `(version-string, version-info)` from `added_value/version.py`.
482330
def read_version():
    ""
    version_file = local_file('source', 'added_value', 'version.py')
    local_vars = {}
    with open(version_file) as handle:
        exec(handle.read(), {}, local_vars)  # pylint: disable=exec-used
    return local_vars['__version__']
32032
def version(path):
    
    version_file = read(path)
    version_match = re.search(r"""^__version__ = ['"]([^'"]*)['"]""",
                              version_file, re.M)
    if version_match:
        return version_match.group(1)
    raise RuntimeError("Unable to find version string.")
572517
def get_version():
    
    if not os.path.exists(VERSION_FILE):
        raise VersionNotFound(VERSION_FILE + " does not exist")
    fp = open(VERSION_FILE, "r")
    vline = None
    for x in fp.readlines():
        x = x.rstrip()
        if not x:
            continue
        if not x.startswith("__version__"):
            continue

        vline = x.split('=')[1]
        break
    if not vline:
        raise VersionNotFound("version file present but has no contents")

    return vline.strip().rstrip().replace("'", '')
584113
def get_version(*file_paths):
    """"""
    filename = os.path.join(os.path.dirname(__file__), *file_paths)
    print("Looking for version in: {}".format(filename))
    version_file = open(filename).read()
    version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]", version_file, re.M)
    if version_match:
        return version_match.group(1)
    raise RuntimeError('Unable to find version string.')
658535
def _get_version():
    """"""
    with open(os.path.join(os.path.dirname(__file__), PACKAGE_NAME, 'VERSION'), 'rb') as f:
        version = f.read().decode('ascii').strip()
    return version
404554
def get_version(package_name, version_file='_version.py'):
    """"""
    filename = os.path.join(os.path.dirname(__file__), package_name, version_file)
    with open(filename, 'rb') as fp:
        return fp.read().decode('utf8').split('=')[1].strip(" \n'")
791246
def get_version():
	
	version_py = os.path.join(os.path.dirname(__file__), 'deepgram', 'version.py')
	with open(version_py, 'r') as fh:
		for line in fh:
			if line.startswith('__version__'):
				return line.split('=')[-1].strip().replace('"', '')
	raise ValueError('Failed to parse version from: {}'.format(version_py))
573563
def stored_version(self, name):
        """"""
        link_path = self._link_path(name)
        if not _path_exists(link_path):
            return None
        return _file_version(link_path)
1055639
def my_version():
    """"""
    if os.path.exists(resource_filename(__name__, 'version')):
        return resource_string(__name__, 'version')

    return open(os.path.join(os.path.dirname(__file__),
                             "..", "version")).read()
393968
def version(modfile):
    '''
    
    '''
    import re
    with open(modfile) as fh:
        for line in fh:
            m = re.search(r"^__version__ = '([^']+)'$", line)
            if m:
                return m.group(1)
    raise Exception('No __version__ string found in {fn}'.format(fn=modfile))
639136
def get_version_details(path):
    

    with open(path, "r") as reader:
        lines = reader.readlines()
        data = {
            line.split(" = ")[0].replace("__", ""):
                line.split(" = ")[1].strip().replace("'", "")
            for line in lines
        }
        return data
522484
def _get_version():
    
    with open('Lib/fontParts/__init__.py', 'r', encoding='utf-8') as f:
        for line in f:
            if line.startswith(u'__version__'):
                return ast.parse(line).body[0].value.s
        raise RuntimeError("No __version__ string found!")
1044886
def _get_version():
    """"""

    with open(join(dirname(__file__), '{{project.package}}/VERSION'), 'rb') as f:
        version = f.read().decode('ascii').strip()
    return version
846959
def _parse_version(self, line):
        
        version_string = line.split(' ')[1]
        version_list = version_string.split('.')
        major_version = ''.join([version_list[0], version_list[1]])
        release_num = ''.join([version_list[2].rstrip(), "-03"])
        return (major_version, release_num)
1161079
def compare_version(value):
    

    # extract parts from value
    import re
    res = re.match(r'(<|<=|==|>|>=)(\d{1,2}\.\d{1,2}(\.\d{1,2})?)$',
                   str(value).strip())
    if not res:
        return False
    operator, value, _ = res.groups()

    # break into pieces
    value = tuple(int(x) for x in str(value).split('.'))
    if len(value) < 3:
        value += (0,)

    version = __version_info__

    if operator in ('<', '<='):
        if version < value:
            return True

        if operator != '<=':
            return False

    elif operator in ('>=', '>'):
        if version > value:
            return True

        if operator != '>=':
            return False

    return value == version
63556
def version_str(version):
    
    if isinstance(version, str):
        return version
    elif isinstance(version, tuple):
        return '.'.join([str(int(x)) for x in version])
    else:
        raise ValueError("Invalid version: %s" % version)
223693
def version():
    """"""
    with open(os.path.join(os.path.abspath(os.path.dirname(__file__)),
                           'pep8radius',
                           'main.py')) as input_file:
        for line in input_file:
            if line.startswith('__version__'):
                return parse(line).body[0].value.s