diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2016-12-05 11:29:45 -0800 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2016-12-05 11:29:45 -0800 |
commit | b0288e3bb41f5f0aead9d38a98112298eaee5e1c (patch) | |
tree | 6aebe6c0ea8dafc445dbeae49ba1ca44edb6b245 /lib | |
parent | 8b1600d825a7f9509f9448d0b831b8a07c9aec02 (diff) | |
download | chef-b0288e3bb41f5f0aead9d38a98112298eaee5e1c.tar.gz |
fix yum regexp similarly to rpm regexp in #3985lcg/fix-yum-regexp
this is a "nope, aint got time to test this one" PR.
this affects a code path that is only for localinstalls and doesn't have
any existing tests.
i've already exceeded my 5 minute timebox for fixing the problem.
i'm more likely to rewrite the yum provider from scratch and shitcan the
unit tests in their entirety than to reuse any work that i do here so
any time spent on carefully testing this is likely to end up wasted.
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/chef/provider/package/yum.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/provider/package/yum.rb b/lib/chef/provider/package/yum.rb index 022fdcae09..8b7d7a5083 100644 --- a/lib/chef/provider/package/yum.rb +++ b/lib/chef/provider/package/yum.rb @@ -197,7 +197,7 @@ class Chef Chef::Log.debug("#{@new_resource} checking rpm status") shell_out_with_timeout!("rpm -qp --queryformat '%{NAME} %{VERSION}-%{RELEASE}\n' #{@new_resource.source}", :timeout => Chef::Config[:yum_timeout]).stdout.each_line do |line| case line - when /([\w\d_.-]+)\s([\w\d_.-]+)/ + when /^(\S+)\s(\S+)$/ @current_resource.package_name($1) @new_resource.version($2) end |