diff options
author | Andreas Gerstmayr <andreas@andreasgerstmayr.at> | 2012-03-18 17:26:54 +0100 |
---|---|---|
committer | Andreas Gerstmayr <andreas@andreasgerstmayr.at> | 2012-03-18 17:26:54 +0100 |
commit | 0f362a13bfafdd14393bdd370e9d196540365837 (patch) | |
tree | 806ba1d2cb1ae916d537b8aa7c22ae0bd4917e8b /lib | |
parent | a63d0380a478344672fd1c05c2aafe19e75a8c54 (diff) | |
download | puppet-vcsrepo-0f362a13bfafdd14393bdd370e9d196540365837.tar.gz puppet-vcsrepo-0f362a13bfafdd14393bdd370e9d196540365837.tar.bz2 |
add begin/except for hg pull (mercurial 2.1 returns 1 for hg pull when no changes are found; this change gets reverted in mercurial 2.1.1)
Diffstat (limited to 'lib')
-rw-r--r-- | lib/puppet/provider/vcsrepo/hg.rb | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/puppet/provider/vcsrepo/hg.rb b/lib/puppet/provider/vcsrepo/hg.rb index 54205c2..0be5e08 100644 --- a/lib/puppet/provider/vcsrepo/hg.rb +++ b/lib/puppet/provider/vcsrepo/hg.rb @@ -65,7 +65,10 @@ Puppet::Type.type(:vcsrepo).provide(:hg, :parent => Puppet::Provider::Vcsrepo) d def revision=(desired) at_path do - hg('pull') + begin + hg('pull') + rescue + end begin hg('merge') rescue Puppet::ExecutionFailure |