This is my first attempt at publishing a package on GitHub.
I am using 1. my GitHub username as the username and 2. a PAT with the necessary scopes (I think: delete:packages, repo, write:packages ) as the password. Both are set in my
~/.gradle/gradle.properties, and they look right when I
println from the
However, when I issue
gradle publish, the result is:
Execution failed for task ':publishGprPublicationToMavenRepository'. > Failed to publish publication 'mavenJava' to repository 'GitHubPackages' > Could not PUT 'https://maven.pkg.github.com/hansi_b/moss/org/hansi_b/moss/0.2.0/moss-0.2.0.jar'. Received status code 401 from server: Unauthorized
I get the same error if I mess up either the username or the password on purpose. Is there any way to get further information on what is going wrong? Is there some piece of configuration I am missing?
I’d be grateful for any pointers.