check:github
Verify GitHub credentials from the .env file.
Usage
splent check:github
Description
Reads GITHUB_USER and GITHUB_TOKEN from the environment and:
- Checks both variables are present and non-empty.
- Calls
GET /useron the GitHub API to verify the token is valid. - Confirms the authenticated user matches
GITHUB_USER. - Displays account name, plan, and remaining API rate limit.
The token is masked in the output (ghp_****...****).
Example output
🐙 GitHub Credentials Check
[✔] GITHUB_USER = splent-dev
[✔] GITHUB_TOKEN = ghp_****...****0b
Contacting GitHub API...
[✔] Authenticated as splent-dev
[✔] Name: Alex Rivera
[✔] Plan: free
[✔] Rate limit: 4998/5000 remaining
✅ GitHub credentials OK.
Requirements
| Variable | Description |
|---|---|
GITHUB_USER |
Your GitHub username. |
GITHUB_TOKEN |
A personal access token (classic) with repo scope. |
Generate a token at: github.com/settings/tokens