From 833a75eff3ec1aee81f4c507fa88ec0150f707f9 Mon Sep 17 00:00:00 2001 From: Onsi Fakhouri Date: Tue, 31 Jan 2023 18:32:39 -0700 Subject: [PATCH] Update index.md with instructions on how to upgrade Ginkgo fixes #1129 --- docs/index.md | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/docs/index.md b/docs/index.md index 92c52a457..adc6b0064 100644 --- a/docs/index.md +++ b/docs/index.md @@ -46,7 +46,25 @@ This fetches Ginkgo and installs the `ginkgo` executable under `$GOBIN` - you'll You should now be able to run `ginkgo version` at the command line and see the Ginkgo CLI emit a version number. -**Note** you _must_ make sure the version of the `ginkgo` cli you install is the same as the version of Ginkgo in your `go.mod` file. +**Note** you _must_ make sure the version of the `ginkgo` cli you install is the same as the version of Ginkgo in your `go.mod` file. You can do this by running `go install github.com/onsi/ginkgo/v2/ginkgo` from your package. + +#### Upgrading Ginkgo + +To upgrade Ginkgo run: + +```bash +go get github.com/onsi/ginkgo/v2/ginkgo +go install github.com/onsi/ginkgo/v2/ginkgo +``` + +To pick a particular version: + +```bash +go get github.com/onsi/ginkgo/v2/ginkgo@v2.m.p +go install github.com/onsi/ginkgo/v2/ginkgo +``` + +Note that in both cases we `go get` the `/v2/ginkgo` subpackage. This pulls in the CLI and its dependencies. If you only `go get github.com/onsi/ginkgo/v2` you may experience issues installing the cli - if you do simply run `go get github.com/onsi/ginkgo/v2/ginkgo` to fetch the missing dependencies. ### Support Policy