powerloader
powerloader copied to clipboard
For ghcr.io we can fetch a default user
Using something like:
curl \
-H "Accept: application/vnd.github.v3+json" \
-H "Authorization: token $GHA_PAT" \
https://api.github.com/user
That works:
❯ gh api /user | jq .login
"dhirschfeld"
..and is a good default if the GHA_USER env var isn't set, but it won't work for organisation owned packages (which is fine, since it's just a default in case of missing config)