Troubleshooting

Common issues and solutions when using godegit.

Troubleshooting

Permission denied

If you see a permission error when running godegit:

chmod +x /usr/local/bin/godegit

If the error occurs during installation, try installing to a user directory instead:

pnpm add -g godegit

Rate limiting

GitHub applies API rate limits to unauthenticated requests. If you hit the limit:

  1. Wait a few minutes and try again
  2. Set a personal access token for higher limits:
export GITHUB_TOKEN=your_token_here
godegit user/repo

Network errors

If godegit fails with a network error:

  • Check your internet connection
  • Run with --verbose to see detailed error output:
godegit user/repo --verbose
  • Confirm GitHub is reachable from your network

Repository not found

If godegit reports the repository cannot be found:

  • Double-check the repository path (user/repo or full URL)
  • For private repositories, set the GITHUB_TOKEN environment variable
  • Verify the branch name with --branch if you specified one

Large repositories

For very large repositories, consider downloading only the subdirectory you need:

# Instead of the full repo
godegit large-org/large-repo/specific/folder

See Subdirectories for details.