Skip to content

Instantly share code, notes, and snippets.

@robwilde
Forked from dhargitai/composerOauthToken.md
Created October 20, 2021 13:35
Show Gist options
  • Save robwilde/ea7f88544948e7c198e0a7aa19455157 to your computer and use it in GitHub Desktop.
Save robwilde/ea7f88544948e7c198e0a7aa19455157 to your computer and use it in GitHub Desktop.
Stop Composer asking for GitHub credentials

Because of GitHub's rate limits on their API it can happen that Composer prompts for authentication asking your username and password so it can go ahead with its work.

If you would prefer not to provide your GitHub credentials to Composer you can manually create a token using the following procedure:

Create an OAuth token on GitHub.

Add it to the configuration running composer config -g github-oauth.github.com <oauthtoken>

Now Composer should install/update without asking for authentication.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment