Description of the feature request:
Add a way of querying for repo mappings, for usage in external tools (such as language servers). The repo mapping is necessary for these tools to resolve labels to files on disk, since the files live under the canonical repo name.
Which category does this issue belong to?
External Dependency
What underlying problem are you trying to solve with this feature?
Facebook have a starlark parser & lsp which works pretty great with Bazel. However, it doesn't support bzlmod because it assumes the repo name of a label is the canonical name, i.e. it looks up @foo in $(bazel info output_base)/external/foo.
According to @fmeum, this is needed for intellij too.
Which operating system are you running Bazel on?
No response
What is the output of bazel info release?
No response
If bazel info release returns development version or (@non-git), tell us how you built Bazel.
No response
What's the output of git remote get-url origin; git rev-parse master; git rev-parse HEAD ?
No response
Have you found anything relevant by searching the web?
No response
Any other information, logs, or outputs that you want to share?
Slack discussion: https://bazelbuild.slack.com/archives/C014RARENH0/p1703107424515999
Description of the feature request:
Add a way of querying for repo mappings, for usage in external tools (such as language servers). The repo mapping is necessary for these tools to resolve labels to files on disk, since the files live under the canonical repo name.
Which category does this issue belong to?
External Dependency
What underlying problem are you trying to solve with this feature?
Facebook have a starlark parser & lsp which works pretty great with Bazel. However, it doesn't support bzlmod because it assumes the repo name of a label is the canonical name, i.e. it looks up
@fooin$(bazel info output_base)/external/foo.According to @fmeum, this is needed for intellij too.
Which operating system are you running Bazel on?
No response
What is the output of
bazel info release?No response
If
bazel info releasereturnsdevelopment versionor(@non-git), tell us how you built Bazel.No response
What's the output of
git remote get-url origin; git rev-parse master; git rev-parse HEAD?No response
Have you found anything relevant by searching the web?
No response
Any other information, logs, or outputs that you want to share?
Slack discussion: https://bazelbuild.slack.com/archives/C014RARENH0/p1703107424515999