Allow the list of fine grained hashes to be defined by a file #277
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I want to make sure all of the rules_go managed "external" Go libraries (eventually represented as Bazel "repos") are considered when hashing occurs.
Without this PR, it seems that I would need to list them all out in a comma separated string param using
--fineGrainedHashExternalRepos
, which risks exceeding the bash arg length. Because in rules_go, each go dependency becomes an individually addressable bazel repo, the argument length would explode because I have hundreds of Go libraries listed in my go.mod which are seen as hundreds of Bazel repos due to MODULE.bazel notation that ultimately looks like this:Right there, that's two separate Bazel repos.. but in reality, there will be hundreds of them.
For this reason, I'm proposing this PR in which the list of repos may be defined in a file, which avoids any glitches with the bash arg length limit.