Skip to content

Commit

Permalink
(helm): update Cobra to latest version
Browse files Browse the repository at this point in the history
This commit forces ([[override]]) the version of Cobra to the
tip of master.  The latest tagged release of Cobra is one week shy
of being a year old and is missing important fixes. An override
is necessary because the Kustomize package requires a tagged
version, so a [[constraint]] is rejected by dep.

The version of Cobra used in dev-v3 is older than the one used
for the master branch (helm v2). Although the dev-v3 branch
was based on master and therefore had the same Cobra version
originally, it was changed a couple of times to choose Cobra
tagged versions instead.

However, the latest Cobra tagged version is older than the version
of Cobra used on the master branch. Therefore, some of the
improvements made to Cobra and used by helm v2 are not available
to helm v3 currently.

This commit brings Cobra to its latest available commit for
helm v3. Originally, I thought of selecting the same Cobra version
in v3 as for helm v2, but after reviewing the 5 extra commits
added to Cobra, I felt it was safe and valuable to bring them in
also.

Bringing Cobra up-to-date is essential for upcoming work being
prepared for dynamic bash-completion; there are bug fixes in
Cobra that are necessary for dynamic bash-completion to work
properly. Specifically,
   spf13/cobra#730
which fixes
   spf13/cobra#694
is essential to avoid the risk of colliding and possibly
breaking kubectl dynamic bash-completion once helm v3 has its
own dynamic completion.

Signed-off-by: Marc Khouzam <marc.khouzam@ville.montreal.qc.ca>
  • Loading branch information
marckhouzam committed May 7, 2019
1 parent b8bced2 commit 3cf1f85
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 45 deletions.
50 changes: 5 additions & 45 deletions Gopkg.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions Gopkg.toml
Original file line number Diff line number Diff line change
Expand Up @@ -105,3 +105,7 @@
[[constraint]]
name = "github.com/xeipuuv/gojsonschema"
version = "1.1.0"

[[override]]
name = "github.com/spf13/cobra"
branch = "master"

0 comments on commit 3cf1f85

Please sign in to comment.