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

Allow soldeer commands to run outside of the project root #145

Open
beeb opened this issue Aug 17, 2024 · 3 comments
Open

Allow soldeer commands to run outside of the project root #145

beeb opened this issue Aug 17, 2024 · 3 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@beeb
Copy link
Collaborator

beeb commented Aug 17, 2024

Currently, soldeer assumes that the dependencies dir, the lock file, the foundry config file, the soldeer config file and the remappings file are localed in the current working directory. We could allow for more flexibility (running soldeer commands from a sub-directory) by traversing the file tree upwards until we find a foundry project root (a folder that contains a foundry.toml or soldeer.toml file), instead of using env::current_dir().

@mario-eth mario-eth added enhancement New feature or request good first issue Good for newcomers labels Aug 18, 2024
@mario-eth
Copy link
Owner

maybe a better idea is to have an arg? I'm not sure if traversing upwards is the right approach.

@beeb
Copy link
Collaborator Author

beeb commented Aug 18, 2024

It's not a great UX if a user has to pass an additional arg if they want to run soldeer install package~version from the src or test directory (that's an example).

Besides, this is how foundry does it

@mario-eth
Copy link
Owner

Hmm, ok, then we should do it this way then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants