diff --git a/fern/products/sdks/overview/go/publishing-to-go-package-manager.mdx b/fern/products/sdks/overview/go/publishing-to-go-package-manager.mdx index a846597de..caf8162f4 100644 --- a/fern/products/sdks/overview/go/publishing-to-go-package-manager.mdx +++ b/fern/products/sdks/overview/go/publishing-to-go-package-manager.mdx @@ -4,8 +4,7 @@ description: Learn how to publish your Fern-generated Go SDK to pkg.go.dev. Conf --- Publish your public-facing Fern Go SDK to -[pkg.go.dev](https://proxy.golang.org/). After following the steps on this page, -you'll have a versioned package published on pkg.go.dev. +[pkg.go.dev](https://pkg.go.dev/). Versioned package published on Pkgsite @@ -13,13 +12,15 @@ you'll have a versioned package published on pkg.go.dev. - - To successfully publish your SDK as a Go module, your repository must have: - * **Public** visibility - * An [approved license](https://pkg.go.dev/license-policy) (e.g. [MIT](https://opensource.org/license/mit), [Apache](https://www.apache.org/licenses/LICENSE-2.0)) - +## Requirements - +Go SDKs are automatically published to [pkg.go.dev](https://pkg.go.dev/) when you push a semantic version tag to your repository and the repository meets the below requirements. No dedicated CI is needed. + +Your repository must have: + +- Public visibility +- An [approved license](https://pkg.go.dev/license-policy) such as [MIT](https://opensource.org/license/mit) or [Apache 2.0](https://www.apache.org/licenses/LICENSE-2.0) +- A valid module path in `go.mod`, which determines your publish URL. For example, `github.com/your-org/your-sdk` publishes to `https://pkg.go.dev/github.com/your-org/your-sdk`. If your module path includes a major version suffix like `/v2`, your SDK publishes to that versioned URL instead (`https://pkg.go.dev/github.com/your-org/your-sdk/v2`). ## Configure `generators.yml` @@ -64,16 +65,16 @@ you'll have a versioned package published on pkg.go.dev. - + - Navigate to `https://pkg.go.dev/github.com///` and send a request to index your package. In a few minutes, your new release should be published to [https://pkg.go.dev/](https://pkg.go.dev/)! + Once the semantic version tag is pushed, pkg.go.dev will automatically index your package. Navigate to `https://pkg.go.dev/` to verify your SDK is published. After releasing a new version, it may take a few minutes for pkg.go.dev - to index and display the update. You can also try checking to see if the Go + to index and display the update. You can also check if the Go proxy has indexed your module at - `https://proxy.golang.org/github.com///@v/list`. pkg.go.dev - indexing usually happens within 5-15 min of the proxy picking it up. + `https://proxy.golang.org//@v/list`. pkg.go.dev + indexing usually happens within 5-15 minutes of the proxy picking it up. For more information, see Go's documentation on [Adding a package](https://pkg.go.dev/about#adding-a-package).