|
From: | Christina O'Donnell |
Subject: | [bug#69827] Fixing the go importer so that it can import modules located in a monorepo |
Date: | Sat, 16 Mar 2024 10:45:21 +0000 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.15.0 |
Hi,These three patches above allow the go importer to automatically import modules that are located in a monorepo where the submodules are versioned independently. See https://go.dev/ref/mod#vcs-version:
> If a module is defined in a subdirectory within the repository, that is, the module subdirectory portion of the module path is not empty, then each tag name must be prefixed with the module subdirectory, followed by a slash. For example, the module golang.org/x/tools/gopls is defined in the gopls subdirectory of the repository with root path golang.org/x/tools. The version v0.4.0 of that module must have the tag named gopls/v0.4.0 in that repository.
After this change, I am able to import github.com/gohugio/hugo and its 400 odd dependencies with much fewer failures.
I'll submit those patches separately once I've tested them. Kind regards, ChristinaPS. This is my first time sending a patch series to debbugs, so I almost certainly did something wrong. Feedback on that would be appreciated.
[Prev in Thread] | Current Thread | [Next in Thread] |