Skip to content

Commit

Permalink
Use non-greedy dot to match version
Browse files Browse the repository at this point in the history
  • Loading branch information
gileri committed Jun 17, 2024
1 parent a8cdff6 commit afa9fff
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugins/module_utils/helm.py
Original file line number Diff line number Diff line change
Expand Up @@ -184,10 +184,10 @@ def get_helm_binary(self):
def get_helm_version(self):
command = self.get_helm_binary() + " version"
rc, out, err = self.run_command(command)
m = re.match(r'version.BuildInfo{Version:"v([^"]*)",', out)
m = re.match(r'version.BuildInfo{Version:"v(.*?)",', out)
if m:
return m.group(1)
m = re.match(r'Client: &version.Version{SemVer:"v([^"]*)", ', out)
m = re.match(r'Client: &version.Version{SemVer:"v(.*?)", ', out)
if m:
return m.group(1)
return None
Expand Down

0 comments on commit afa9fff

Please sign in to comment.