Edits the related entry in ssh config.
492951
def edit(name, connection_uri, id_file="", o=[], config=None):
    
    storm_ = get_storm_instance(config)

    try:
        if ',' in name:
            name = " ".join(name.split(","))

        user, host, port = parse(
            connection_uri,
            user=get_default("user", storm_.defaults),
            port=get_default("port", storm_.defaults)
        )

        storm_.edit_entry(name, host, user, port, id_file, o)
        print(get_formatted_message(
            '"{0}" updated successfully.'.format(
                name
            ), 'success'))
    except ValueError as error:
        print(get_formatted_message(error, 'error'), file=sys.stderr)
        sys.exit(1)
589971
def do_edit(self, args):
        """"""
        if 'EDITOR' not in os.environ:
            print('*** $EDITOR not set')
        else:
            path = os.path.join(utils.CONFIG_DIR, 'sql')
            cmd = os.environ['EDITOR']
            try:
                os.system(cmd + ' ' + path)
                if os.path.exists(path):
                    with open(path, 'r') as f:
                        sql = f.read()
                        if sql:
                            self.default(sql)
            finally:
                if os.path.exists(path):
                    os.remove(path)
275657
def edit(user_name, repo_name, key_id, params={})
      _update_user_repo_params(user_name, repo_name)
      _validate_user_repo_params(user, repo) unless user? && repo?
      _validate_presence_of key_id

      normalize! params
      filter! VALID_KEY_PARAM_NAMES, params

      put_request("/1.0/repositories/#{user}/#{repo.downcase}/deploy-keys/#{key_id}", params)
    end
824013
public function modifyFile()
    {
        foreach (['chown', 'chgrp', 'chmod'] as $key) {
            $value = $this->{$key};
            if ($value) {
                $this->file->{$key}($value);
            }
        }
    }
645481
def ssh_keyscan(cls, vm_id):
        """"""
        cls.echo('Wiping old key and learning the new one')
        _version, ip_addr = cls.vm_ip(vm_id)
        cls.execute('ssh-keygen -R "%s"' % ip_addr)

        for _ in range(5):
            output = cls.exec_output('ssh-keyscan "%s"' % ip_addr)
            if output:
                with open(os.path.expanduser('~/.ssh/known_hosts'), 'a') as f:
                    f.write(output)
                return True
            time.sleep(.5)
16121
def edit_matching_entry(program, arguments):
    """"""
    entry = program.select_entry(*arguments)
    entry.context.execute("pass", "edit", entry.name)
57566
def edit
      security_transgression_unless @comment.can_be_edited_by?(@user)

      respond_to do |format|
        format.html { redirect_to @thread }
        format.js
      end
    end
429290
public static void modifySystemConfig(IConfigKey key, String value) throws IOException {
        systemConfigs.modifyConfig(key, value);
    }
1279380
def edit(self, pk):
        """"""
        resp = super(TableModelView, self).edit(pk)
        if isinstance(resp, str):
            return resp
        return redirect('/superset/explore/table/{}/'.format(pk))
1017549
def modify_kls(self, name):
        """"""
        if self.kls is None:
            self.kls = name
        else:
            self.kls += name
1277145
def edit
    @config_var = ConfigVar.where(name: params[:name]).first
    unless @config_var
      @config_var = ConfigVar.new name: params[:name]
      if descriptor = ConfigvarsRails.variable_descriptor(params[:name])
        @config_var.value = descriptor.default_value
      end
    end
  end
724446
void merge(RepositoryInfo entry)
   {
      if (systemWorkspaceName == null)
         setSystemWorkspaceName(entry.systemWorkspaceName);
      if (defaultWorkspaceName == null)
         setDefaultWorkspaceName(entry.defaultWorkspaceName);
      if (accessControl == null)
         setAccessControl(entry.accessControl);
      if (securityDomain == null)
         setSecurityDomain(entry.securityDomain);
      if (authenticationPolicy == null)
         setAuthenticationPolicy(entry.authenticationPolicy);
      if (sessionTimeOut == 0)
         setSessionTimeOut(entry.sessionTimeOut);
      if (lockRemoverMaxThreadCount == 0)
         setLockRemoverThreadsCount(entry.lockRemoverMaxThreadCount);
   }
1228230
def configure_root_access(options = {})
      public_key = ENV['VS_SSH_PUBLIC_KEY'].to_s.strip
      # was there a key found?
      if public_key.nil? || public_key.empty?
        puts "No public SSH key found in metadata"
        return
      end
      update_authorized_keys(public_key)
    end
583446
def edit(self):
        
        subprocess.call("{0} {1}".format(self.meta.editor,
                                         self.config_file), shell=True)
524670
def commit_config(self):
        """"""
        self.device.cu.commit(ignore_warning=self.ignore_warning)
        if not self.config_lock:
            self._unlock()
253118
def edit_entry(self, id_, **kwargs):
        
        data = self._wrap_dict("time_entry", kwargs)

        return self.patch("/time_entries/{}.json".format(id_), data)
1103559
def update_ssh_key(self, name):
        # The `_ssh_key` is to avoid conflicts with MutableMapping.update.
        
        api = self.doapi_manager
        return api._ssh_key(api.request(self.url, method='PUT',
                                       data={"name": name})["ssh_key"])