Returns the version from package.json.
@name version
340821
function version() {
  const packageJson = require(path.resolve(__dirname, '..', 'package.json'));
  logger.info('@blackbaud/skyux-builder: %s', packageJson.version);
}
419039
function readPackageVersion(root) {
  let pkg = JSON.parse(fs.readFileSync(path.join(root, 'package.json'), 'utf8'));
  // use _originalVersion if present if we've already mutated it
  return pkg._originalVersion || pkg.version;
}
663082
def package_version(self):
        """"""
        vbase = self.base_version
        if self.ncommits:
            vbase += '.dev{0}+{1}'.format(self.ncommits, self.sha)
        return vbase
1372623
def _version_view(self):
        
        version_json = self._version_callback(self.version_path)
        if version_json is None:
            return 'version.json not found', 404
        else:
            return jsonify(version_json)
772005
def do_version():
    """"""
    v = ApiPool.ping.model.Version(
        name=ApiPool().current_server_name,
        version=ApiPool().current_server_api.get_version(),
        container=get_container_version(),
    )
    log.info("/version: " + pprint.pformat(v))
    return v
304145
def get_version(package):
    
    init_py = codecs.open(os.path.join(package, '__init__.py'), encoding='utf-8').read()
    return re.search("^__version__ = ['\"]([^'\"]+)['\"]", init_py, re.MULTILINE).group(1)
1290970
def get_version():
    """"""
    try:
        # Try with the package manager, if present
        from pkg_resources import resource_string
        return resource_string(__name__, "VERSION.txt").decode('utf8').strip()
    except Exception:
        # If the package manager is not present, try reading the file
        version = os.path.join(os.path.dirname(__file__), "VERSION.txt")
        with open(version, "r") as f:
            return f.readlines()[0].strip()
483862
def get_package_version(module_obj, value):
    
    for key in ['version', '__version__']:
        if hasattr(module_obj, key):
            return getattr(module_obj, key)
    parts = value.split('.')
    for index, part in enumerate(parts):
        try:
            return pkg_resources.get_distribution(
                '.'.join(parts[0:index + 1])).version
        except (pkg_resources.DistributionNotFound,
                pkg_resources.RequirementParseError):
            continue
968857
def get_package_version(self):
        
        output = subprocess.check_output([
            '{}'.format(self.python),
            'setup.py',
            '--version',
        ]).decode()
        return output.rstrip()
911130
function determineVersion(json) {
	var version = 'unknown';
	if (json) {
		if (json.WMS_Capabilities) {
			if (json.WMS_Capabilities.$) {
				if (json.WMS_Capabilities.$.version) {
					version = json.WMS_Capabilities.$.version;
				}
			}
		} else {
			if (json.WMT_MS_Capabilities) {
				if (json.WMT_MS_Capabilities.$) {
					if (json.WMT_MS_Capabilities.$.version) {
						version = json.WMT_MS_Capabilities.$.version;
					}
				}
			}
		}
	}
	return version;
}
1011681
function getVersion (plugin) {
  return new Promise(function (resolve, reject) {
    npm.commands.view([plugin, 'version'], function (err, data) {
      if (err) return reject(err)
      resolve(Object.keys(data)[0])
    })
  })
}
467441
def get_version(package):
    
    init_py = readfile(os.path.join(package, '__init__.py'))
    return re.search("__version__ = ['\"]([^'\"]+)['\"]", init_py).group(1)
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'")
785277
def get_package_version():
    """"""
    base = os.path.abspath(os.path.dirname(__file__))
    with open(os.path.join(base, 'policy', '__init__.py'),
              mode='rt',
              encoding='utf-8') as initf:
        for line in initf:
            m = version.match(line.strip())
            if not m:
                continue
            return m.groups()[0]
294850
function getPackageInfoFrom(string) {
  if (string[0] === '@') {
    const [scope, rawName] = string.split('/');
    const { name, version } = getVersionFromString(rawName);
    return {
      name: `${scope}/${name}`,
      version,
    };
  }

  return getVersionFromString(string);
}
128214
def get_version(package):
    """"""
    with io.open(os.path.join(BASE_DIR, package, '__init__.py'), encoding='utf-8') as fh:
        return [
            l.split('=', 1)[1].strip().strip("'").strip('"')
            for l in fh.readlines()
            if '__version__' in l][0]
85025
def _check_version(version):
    """"""
    if version != pyphi.__version__:
        raise pyphi.exceptions.JSONVersionError(
            'Cannot load JSON from a different version of PyPhi. '
            'JSON version = {0}, current version = {1}.'.format(
                version, pyphi.__version__))