Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot override TokenSource without a root project #42

Open
hejfelix opened this issue Oct 15, 2021 · 1 comment
Open

Cannot override TokenSource without a root project #42

hejfelix opened this issue Oct 15, 2021 · 1 comment

Comments

@hejfelix
Copy link

Not specifying a root project will silently not allow you to override the the TokenSource. While it might not be the fault of this plugin, it's a big gotcha that might be causing a lot of confusion for others.
This combined with the fact that e.g. bloopInstall will try to evaluate the token can quickly lead to some head scratching. Maybe mentioning this in the README could help?

@lonniev
Copy link

lonniev commented Nov 4, 2021

We resolved similar issues (with use of the Lagom plugin’s runAll task) by removing this plugin (which served an informative purpose) and then much more directly declaring suitable Credentials entries.

When this plugin is studied, one comes to see that it does three things and nothing more:

  1. It retrieves a token value from the first of two fixed choices: an env variable or the output of the git config query
  2. It maps the user’s organization, repo, user id, and token to a suitable Credentials entry
  3. It auto-binds itself to all explicitly defined and any dynamically instantiated projects

It is step 3 that causes the grief in moderately complex SBT builds.

If you don’t need all the (understandably) opinionated assumptions it makes and you don’t want its tactics and requirements associated with each and every project, then (rather simply) state the Credentials entries needed to authenticate with GH Packages sites and treat GitHub Packages like another other maven-like package repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants