-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Description
Component
Forge
Have you ensured that all of these are up to date?
- Foundry
- Foundryup
What version of Foundry are you on?
forge 0.3.0 (68aff72 2024-12-31T00:22:19.465395448Z)
What command(s) is the bug in?
forge install
Operating System
Linux
Describe the bug
I have a fork (https://github.com/CodeSandwich/era-contracts/) of a repo (https://github.com/matter-labs/era-contracts) that I want to use as a dependency. I had the upstream installed as a dependency, so to keep it clean I uninstalled it (git rm lib/era-contracts && git commit, which removed lib/era-contracts and the entry from .gitmodules) and installed it again with forge install CodeSandwich/era-contracts. The installation succeeded, it added the appropriate [submodule "lib/era-contracts"] to .gitmodules along with the correct url = https://github.com/CodeSandwich/era-contracts, but when I go to lib/era-contracts, it's the upstream that is installed. When I cd lib/era-contracts/ and git remote, I get just origin, but git remote get-url origin returns https://github.com/matter-labs/era-contracts, which is the upstream. Of course I can't check out my fork's branch in the installed dependency submodule, it's the upstream after all. Also when doing forge install CodeSandwich/era-contracts@fix_system_contracts which is my branch, I get Error: Tag: "fix_system_contracts" not found for repo "https://github.com/CodeSandwich/era-contracts"!, which is wrong but makes some sense since forge installs the upstream, but it also seems aware that I'm asking for the fork.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status