Open agkphysics opened 4 days ago
Hey @agkphysics, I can't really see any problem with this off the top of my head but I'm curious what your workflow was that you ended up in this situation? Like, you describe having the token in a file but I'm not sure how you would get that token without the newline being stripped by the shell e.g. GH_TOKEN=$(cat token_file)
Cheers!
@williammartin So in my case it comes from a GitHub secret which contains the token for a custom bot which we use for CI.
I noticed that a workflow was failing because of a trailing newline in the token when trying to use gh
.
But I guess I should ask the maintainer to remove the newline from the secret.
Describe the feature or problem you’d like to solve
gh
should strip whitespace from a token given inGH_TOKEN
.Proposed solution
This will allow cases where the token is stored in a file or string with a trailing newline.
Additional context
Example