2

When I run bundle I get this:

$ bundle
Following files may not be writable, so sudo is needed:
  /Library/Ruby/Gems/2.3.0
  /Library/Ruby/Gems/2.3.0/build_info
  /Library/Ruby/Gems/2.3.0/cache
  /Library/Ruby/Gems/2.3.0/doc
  /Library/Ruby/Gems/2.3.0/extensions
  /Library/Ruby/Gems/2.3.0/gems
  /Library/Ruby/Gems/2.3.0/specifications
Fetching https://github.com/lsegal/yard.git
Fetching https://github.com/lsegal/yard-js.git
Fetching https://github.com/lsegal/parsejs.git
Username for 'https://github.com': me
Password for 'https://me@github.com': 
remote: Invalid username or password.
fatal: Authentication failed for 'https://github.com/lsegal/parsejs.git/'

Retrying `git clone 'https://github.com/lsegal/parsejs.git' "/Users/me/.bundle/cache/git/parsejs-35f0b5a29373e174672dd4f95a4392093a2ddf51" --bare --no-hardlinks --quiet` due to error (2/4): Bundler::Source::Git::GitCommandError Git error: command `git clone 'https://github.com/lsegal/parsejs.git' "/Users/me/.bundle/cache/git/parsejs-35f0b5a29373e174672dd4f95a4392093a2ddf51" --bare --no-hardlinks --quiet` in directory /Users/paulcarron/git/ibm-cos-sdk-js has failed.
Username for 'https://github.com': me
Password for 'https://me@github.com': 
remote: Repository not found.
fatal: repository 'https://github.com/lsegal/parsejs.git/' not found

Retrying `git clone 'https://github.com/lsegal/parsejs.git' "/Users/me/.bundle/cache/git/parsejs-35f0b5a29373e174672dd4f95a4392093a2ddf51" --bare --no-hardlinks --quiet` due to error (3/4): Bundler::Source::Git::GitCommandError Git error: command `git clone 'https://github.com/lsegal/parsejs.git' "/Users/me/.bundle/cache/git/parsejs-35f0b5a29373e174672dd4f95a4392093a2ddf51" --bare --no-hardlinks --quiet` in directory /Users/paulcarron/git/ibm-cos-sdk-js has failed.
Username for 'https://github.com':

I logged in to GitHub through the browser with the same username so don't know what's going on. Can anybody help?

runnerpaul
  • 5,942
  • 8
  • 49
  • 118

1 Answers1

0

You need to create a Github Token to access via the command line API. Go to Settings -> Developer Settings -> Access Tokens and create a new token.

I'm not entirely certain which set you need. I gave myself repo (all), write:packages, read:packages, and workflow because that's what I wanted on that token. My guess is that read:packages will be sufficient.

You can then provide your normal Github username and this new token when bundle prompts for it.

karl
  • 3,544
  • 3
  • 30
  • 46