Updates the track for the provided version code(s)
496813
def update_track(track, rollout, apk_version_code)
      ensure_active_edit!

      track_version_codes = apk_version_code.kind_of?(Array) ? apk_version_code : [apk_version_code]

      # This change happend on 2018-04-24
      # rollout cannot be sent on any other track besides "rollout"
      # https://github.com/fastlane/fastlane/issues/12372
      rollout = nil unless track == "rollout"

      track_body = Androidpublisher::Track.new({
        track: track,
        user_fraction: rollout,
        version_codes: track_version_codes
      })

      call_google_api do
        client.update_track(
          current_package_name,
          current_edit.id,
          track,
          track_body
        )
      end
    end
1237016
private void saveNumberOfChecksForUpdatedVersion(String versionDownloadable, int mChecksMade) {
        mChecksMade++;
        SharedPreferences prefs = mActivity.getSharedPreferences(PREFS_FILENAME, 0);
        SharedPreferences.Editor editor = prefs.edit();
        editor.putInt(SUCCESSFUL_CHEKS_PREF_KEY + versionDownloadable, mChecksMade);
        editor.commit();

    }
1219621
private void update() {
                if (!uptodate) {
                        summary.clear();
                        distinctTraces.clear();
                        traces.clear();
                        addTraces(allTraces, false);
                        uptodate = true;
                }
        }
1335236
protected void updateTrackLocation( SetTrackInfo<Desc> info, FastQueue<AssociatedIndex> matches) {
		info.matches.resize(matches.size);
		for (int i = 0; i < matches.size; i++) {
			info.matches.get(i).set(matches.get(i));
		}

		tracksActive.clear();
		for( int i = 0; i < info.matches.size; i++ ) {
			AssociatedIndex indexes = info.matches.data[i];
			PointTrack track = info.tracks.get(indexes.src);
			Point2D_F64 loc = info.locDst.data[indexes.dst];
			track.set(loc.x, loc.y);
			tracksActive.add(track);
		}
	}
297746
def set_version(portal_type, legacy_version, td):
    """"""
    modified = 'OK'
    legacy_major, legacy_minor = legacy_version.split('.')

    if portal_type == 'Collection':
        # For collections, both major and minor needs to be set
        modified = 'MODIFY'
        td['new']['major_version'] = int(legacy_minor)
        if td['new']['minor_version'] is None:
            td['new']['minor_version'] = 1

    elif portal_type == 'Module':
        # For modules, major should be set and minor should be None
        # N.B. a very few older modules had major=2 and minor zero-based.
        # The odd math below adds one to the minor for those
        modified = 'MODIFY'
        td['new']['major_version'] = int(legacy_minor)+(int(legacy_major)-1)
        td['new']['minor_version'] = None

    return modified
1022723
def update_tracking_terms(self):
        
        import codecs
        with codecs.open(self.filename,"r", encoding='utf8') as input:
            # read all the lines
            lines = input.readlines()

            # build a set of terms
            new_terms = set()
            for line in lines:
                line = line.strip()
                if len(line):
                    new_terms.add(line)

            return set(new_terms)
938140
def _update_pypi_version(self):
        """"""
        logger.debug("Get latest Glances version from the PyPI RESTful API ({})".format(PYPI_API_URL))

        # Update the current time
        self.data[u'refresh_date'] = datetime.now()

        try:
            res = urlopen(PYPI_API_URL, timeout=3).read()
        except (HTTPError, URLError, CertificateError) as e:
            logger.debug("Cannot get Glances version from the PyPI RESTful API ({})".format(e))
        else:
            self.data[u'latest_version'] = json.loads(nativestr(res))['info']['version']
            logger.debug("Save Glances version to the cache file")

        # Save result to the cache file
        # Note: also saved if the Glances PyPI version cannot be grabbed
        self._save_cache()

        return self.data
73446
function updatePackageJSONVersion() {
  let packageJSONPath = path.join(__dirname, '..', 'package.json');

  let pkgContents = fs.readFileSync(packageJSONPath, { encoding: 'utf-8' });
  let pkg = JSON.parse(pkgContents);
  if (!pkg._originalVersion) {
    pkg._originalVersion = pkg.version;
  }
  pkg._versionPreviouslyCalculated = true;
  pkg.version = buildInfo.version;
  fs.writeFileSync(packageJSONPath, JSON.stringify(pkg, null, 2), {
    encoding: 'utf-8',
  });
}
718869
def _upgrade(self):
        
        logging.debug("[FeedbackCalibration]._upgrade()")
        version = Version.fromstring(self.version)
        logging.debug('[FeedbackCalibration] version=%s, class_version=%s',
                      str(version), self.class_version)
        if version > Version.fromstring(self.class_version):
            logging.debug('[FeedbackCalibration] version>class_version')
            raise FutureVersionError(Version.fromstring(self.class_version),
                                     version)
        elif version < Version.fromstring(self.class_version):
            if version < Version(0, 1):
                self._c_filler = None
                self._c_drop = None
                self.version = str(Version(0, 1))
            if version < Version(0, 2):
                self.hw_version = Version(1)
                self.version = str(Version(0, 2))
                logging.info('[FeedbackCalibration] upgrade to version %s',
                             self.version)
            if version < Version(0, 2):
                self.hw_version = Version(1)
                self.version = str(Version(0, 2))
                logging.info('[FeedbackCalibration] upgrade to version %s',
                             self.version)
            if version < Version(0, 3):
                self.version = str(Version(0, 3))
                logging.info('[FeedbackCalibration] upgrade to version %s',
                             self.version)
521371
def _update_version(self):
        """"""
        #current = self.vcs.version
        current = self.data['new_version']

        # Clean it up to a non-development version.
        current = utils.cleanup_version(current)
        # Try to make sure that the suggestion for next version after
        # 1.1.19 is not 1.1.110, but 1.1.20.
        current_split = current.split('.')
        major = '.'.join(current_split[:-1])
        minor = current_split[-1]
        try:
            minor = int(minor) + 1
            suggestion = '.'.join([major, str(minor)])
        except ValueError:
            # Fall back on simply updating the last character when it is
            # an integer.
            try:
                last = int(current[-1]) + 1
                suggestion = current[:-1] + str(last)
            except ValueError:
                logger.warn("Version does not end with a number, so we can't "
                            "calculate a suggestion for a next version.")
                suggestion = None
        print("Current version is %r" % current)
        q = "Enter new development version ('.dev0' will be appended)"
        version = utils.ask_version(q, default=suggestion)
        if not version:
            version = suggestion
        if not version:
            logger.error("No version entered.")
            sys.exit()

        self.data['new_version'] = version
        dev_version = self.data['dev_version_template'] % self.data
        self.data['dev_version'] = dev_version
        logger.info("New version string is %r",
                    dev_version)

        self.vcs.version = self.data['dev_version']
837843
def updateTraceCount(self):
        """"""
        self.ui.ntracesLbl.setNum(self.ui.trackview.model().traceCount())
1070842
def set_version(self, version='0.0.0', save=True):
        """"""
        self.set(self.DEFAULT_SECTION_NAME, 'version', version, save=save)
1130042
def update(self, iteration, fobj):
        """""""
        self.bst.update(self.dtrain, iteration, fobj)
531837
def update_attributes(self, updates):
        """"""
        if not isinstance(updates, dict):
            updates = updates.to_dict()
        for sdk_key, spec_key in self._get_attributes_map().items():
            attr = '_%s' % sdk_key
            if spec_key in updates and not hasattr(self, attr):
                setattr(self, attr, updates[spec_key])
1260915
function updateConfigs (args, newVersion) {
  const dotgit = DotGitignore()
  Bump.pkgFiles.concat(Bump.lockFiles).forEach(function (filename) {
    let configPath = path.resolve(process.cwd(), filename)
    try {
      if (dotgit.ignore(configPath)) return
      let stat = fs.lstatSync(configPath)
      if (stat.isFile()) {
        let data = fs.readFileSync(configPath, 'utf8')
        let indent = detectIndent(data).indent
        let newline = detectNewline(data)
        let config = JSON.parse(data)
        checkpoint(args, 'bumping version in ' + filename + ' from %s to %s', [config.version, newVersion])
        config.version = newVersion
        writeFile(args, configPath, stringifyPackage(config, indent, newline))
        // flag any config files that we modify the version # for
        // as having been updated.
        configsToUpdate[filename] = true
      }
    } catch (err) {
      if (err.code !== 'ENOENT') console.warn(err.message)
    }
  })
}
591340
public synchronized void updateFromTrackParameters(TrackParameters track) {
    parameters.clear();
    for(TrackedParameter p : track.getAllParameters()) {
      Parameter<?> option = p.getParameter();
      String value = null;
      if(option.isDefined()) {
        if(option.tookDefaultValue()) {
          value = DynamicParameters.STRING_USE_DEFAULT + option.getDefaultValueAsString();
        }
        else {
          value = option.getValueAsString();
        }
      }
      if(value == null) {
        value = (option instanceof Flag) ? Flag.NOT_SET : "";
      }
      int bits = 0;
      if(option.isOptional()) {
        bits |= BIT_OPTIONAL;
      }
      if(option.hasDefaultValue() && option.tookDefaultValue()) {
        bits |= BIT_DEFAULT_VALUE;
      }
      if(value.length() <= 0) {
        if((bits & BIT_DEFAULT_VALUE) == 0 && (bits & BIT_OPTIONAL) == 0) {
          bits |= BIT_INCOMPLETE;
        }
      }
      else {
        try {
          if(!option.tookDefaultValue() && !option.isValid(value)) {
            bits |= BIT_INVALID;
          }
        }
        catch(ParameterException e) {
          bits |= BIT_INVALID;
        }
      }
      int depth = 0;
      {
        Object pos = track.getParent(option);
        while(pos != null) {
          pos = track.getParent(pos);
          depth += 1;
          if(depth > 10) {
            break;
          }
        }
      }
      parameters.add(new Node(option, value, bits, depth));
    }
  }
683099
def increment_version(context):
    """"""

    attributes.replace_attribute(
        context.module_name, '__version__', context.new_version, dry_run=context.dry_run
    )
    log.info(
        'Bumped version from %s to %s' % (context.current_version, context.new_version)
    )