Merge pull request #263233 from stelcodes/fix-go-docs

doc: use lib.fakeHash with buildGoModule to get vendorHash

authored by Wael Nasreddine and committed by GitHub 75a52265 791c147c

+1 -1
+1 -1
doc/languages-frameworks/go.section.md
··· 18 19 To avoid updating this field when dependencies change, run `go mod vendor` in your source repo and set `vendorHash = null;` 20 21 - To obtain the actual hash, set `vendorHash = lib.fakeSha256;` and run the build ([more details here](#sec-source-hashes)). 22 - `proxyVendor`: Fetches (go mod download) and proxies the vendor directory. This is useful if your code depends on c code and go mod tidy does not include the needed sources to build or if any dependency has case-insensitive conflicts which will produce platform-dependent `vendorHash` checksums. 23 - `modPostBuild`: Shell commands to run after the build of the goModules executes `go mod vendor`, and before calculating fixed output derivation's `vendorHash` (or `vendorSha256`). Note that if you change this attribute, you need to update `vendorHash` (or `vendorSha256`) attribute. 24
··· 18 19 To avoid updating this field when dependencies change, run `go mod vendor` in your source repo and set `vendorHash = null;` 20 21 + To obtain the actual hash, set `vendorHash = lib.fakeHash;` and run the build ([more details here](#sec-source-hashes)). 22 - `proxyVendor`: Fetches (go mod download) and proxies the vendor directory. This is useful if your code depends on c code and go mod tidy does not include the needed sources to build or if any dependency has case-insensitive conflicts which will produce platform-dependent `vendorHash` checksums. 23 - `modPostBuild`: Shell commands to run after the build of the goModules executes `go mod vendor`, and before calculating fixed output derivation's `vendorHash` (or `vendorSha256`). Note that if you change this attribute, you need to update `vendorHash` (or `vendorSha256`) attribute. 24