如何在 composer (laravel 4) 中删除保存的用户名和密码

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/18416486/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-14 08:19:38  来源:igfitidea点击:

How to remove save username and password in composer (laravel 4)

phpterminallaravellaravel-4composer-php

提问by drexsien

I have updated my laravel vendor using composer. I have bought a package which is located in a github private repo. On downloading composer ask username and password, I have entered the wrong password so it gives me an error. After that I run composer update again but this time it just keep the old wrong password it did not ask me to enter the password again, somewhat save in composer cache. How could I remove the old password in composer?

我已经使用 Composer 更新了我的 Laravel 供应商。我买了一个位于 github 私有仓库中的包。在下载 composer 询问用户名和密码时,我输入了错误的密码,所以它给了我一个错误。之后我再次运行 composer update 但这次它只是保留了旧的错误密码,它没有要求我再次输入密码,有点保存在 composer 缓存中。如何删除作曲家中的旧密码?

回答by netvision73

In your ~/.composer, you'll have a file named config.jsonwhich contains OAuth token used to log you in GitHub.

在您的 中~/.composer,您将有一个名为的文件config.json,其中包含用于将您登录到 GitHub 的 OAuth 令牌。

Clear your OAuth token or delete this file.

清除您的 OAuth 令牌或删除此文件。

回答by Xenocide8998

Mine was in ~/.config/composerin there is a auth.jsonthat contains saved credentials. Like netvision73 answer, clear your OAuth token or delete the file.

我的~/.config/composer在那里有一个auth.json包含保存的凭据。像 netvision73 回答一样,清除您的 OAuth 令牌或删除文件。