diff options
author | Nate Mueller <nate@nearbuysystems.com> | 2011-07-27 19:52:36 -0700 |
---|---|---|
committer | Nate Mueller <nate@nearbuysystems.com> | 2011-07-27 19:52:36 -0700 |
commit | 26308908c72f57d2c8f537f8f761d9d2f6fa739b (patch) | |
tree | bd7f2c24d318451351d16b8898a6e3ba32fab79d /lib | |
parent | 16e2e1efc2cc41f603cf499394d3c117a301a078 (diff) |
Updated for ruby 1.9. Not sure how important this actually is. Works on both now.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/puppet/provider/vcsrepo/git.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/puppet/provider/vcsrepo/git.rb b/lib/puppet/provider/vcsrepo/git.rb index e624b49..6756fc0 100644 --- a/lib/puppet/provider/vcsrepo/git.rb +++ b/lib/puppet/provider/vcsrepo/git.rb @@ -234,7 +234,7 @@ Puppet::Type.type(:vcsrepo).provide(:git, :parent => Puppet::Provider::Vcsrepo) end def on_branch? - at_path { git_with_identity('branch', '-a') }.split(/\n/).grep(/\*/).to_s.gsub('*', '').strip + at_path { git_with_identity('branch', '-a') }.split(/\n/).grep(/\*/).first.to_s.gsub('*', '').strip end def tags @@ -260,7 +260,7 @@ Puppet::Type.type(:vcsrepo).provide(:git, :parent => Puppet::Provider::Vcsrepo) elsif remote_branch_revision? canonical = at_path { git_with_identity('rev-parse', 'origin/' + @resource.value(:revision)).strip } end - current = @resource.value(:revision) if current == canonical + current = @resource.value(:revision) if current == canonical end return current end |