gh-token: Support fetching token from GH_TOKEN and GITHUB_TOKEN envvars
jwodder opened this issue · comments
John T. Wodder II commented
I would like to request that gh-token
gain the ability (either by changing gh_token::get()
or by adding a separate function) to check the GH_TOKEN
and GITHUB_TOKEN
envvars (in that order) for a GitHub token before falling back to reading from the gh
config file, just like gh
does. This would allow gh-token
-enabled programs to run in environments like GitHub Actions where the GitHub token is typically passed as an environment variable.