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

Make relative paths in deps of bb.edn resolve relative to the bb.edn #1473

Closed
lispyclouds opened this issue Jan 24, 2023 · 1 comment
Closed

Comments

@lispyclouds
Copy link
Member

Is your feature request related to a problem? Please describe.
Currently, due to its nature of implementation in deps.clj and its use in bb, if relative paths via :local/root are used in the :deps of bb.edn, they are resolved relative to the pwd of the invocation and not the bb.edn.

Describe the solution you'd like
To make the expectation of all the paths in bb.edn resolve relative to it consistent the resolution of these paths should be changed as well.

Describe alternatives you've considered
None.

Additional context
Some points to consider:

  • Since this is shelling out to the usual deps resolver, how does the classpath caching get affected by this change? Would it pollute the pwd now?
lispyclouds added a commit to lispyclouds/dotfiles that referenced this issue Jan 24, 2023
@borkdude
Copy link
Collaborator

The only change necessary to fix this is to use (:bb-deps-root ...) and bind the deps.clj *dir* variable to it (only if it's set, with-bindings allows you to do that conditionally.

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