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

scalablyTypedBasePath default #16

Open
ajrnz opened this issue Nov 30, 2022 · 2 comments
Open

scalablyTypedBasePath default #16

ajrnz opened this issue Nov 30, 2022 · 2 comments

Comments

@ajrnz
Copy link

ajrnz commented Nov 30, 2022

Would it make more sense for scalablyTypedBasePath to default to millSourcePath / os.up instead of T.workspace?

Currently if you use mill-scalablytyped in a sub or foreign module it will look in the root module for the package.json.

However if you are trying to wrap JS libs it will look in the root project which ruins the encapsulation. I defer to you superior JavaScript knowledge in this. I can work around by:

def scalablyTypedBasePath = T{ millSourcePath / os.up }

(This is effectively T.workspace in a simple project)

@lolgab
Copy link
Owner

lolgab commented Nov 30, 2022

The limiting factor here is that mill doesn't currently allow to run tests in a different wd that T.workspace (see com-lihaoyi/mill#1036).
Maybe after that is fixed we could change the default to millSourcePath, but until that is fixed changing it does more harm than good.

@lolgab
Copy link
Owner

lolgab commented Nov 30, 2022

I defer to you superior JavaScript knowledge in this.

You're way too kind :) My Javascript knowledge is very shallow

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