Documentation
¶
Overview ¶
Command flatpakgo prints the Go modules the app, maild and mailctl need as flatpak-builder `file` sources, so a Flatpak builds offline (docs/adr/0046-the-desktop-flatpak-carries-its-own-maild.md).
Each module becomes 2 sources, its go.mod and its zip, fetched from proxy.golang.org into goproxy/<escaped module>/@v. The build then points GOPROXY at file://$PWD/goproxy. The modules are the ones `go mod download` fetches for this module, and each must have both of its go.sum lines. A module that go.mod replaces with a directory (third_party/go-imap) is no download and no source: the build finds it in the source tree. Run it from the repository root; it needs a populated module cache, which `go mod download` fills, so it runs that first and may use the network.
go run ./tools/flatpakgo [-gosum go.sum] > packaging/flatpak/go-sources.json