foundry-rs / foundry-rs/foundry
feat(`forge`): avoid repulling in dependencies when using git worktree
- Dominant language
- Rust
- Stars
- 10.6k
- Forks
- 2.6k
- Avg merge
- 16h 38m
- Merged PRs (30d)
- 511
Description
### Component
Forge
### Describe the feature you would like
I often find myself in the following situation.
I work on a new feature for repo `r` so I:
```sh
$ cd r
$ git worktree add -b new-feature-a features/new-feature-a
$ cd features/new-feature-a
$ git submodule sync
$ foundry i
```
This process is annoying because I have to sync submodules and install dependencies which is often long, instead I would expect dependencies to be shared across worktrees, or at least cached.
### Additional context
_No response_
Contributor guide
Research direction
Start with the Forge workflow invoked by `foundry i` after `git worktree add`, then examine how `git submodule sync` and dependency installation behave in a worktree. Done means dependencies are shared across worktrees or cached so the documented sequence does not repull or reinstall them unnecessarily.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- git, rust
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100