From ee8ae3c09b8ef3bae0b1317788aa6a02b9433bcd Mon Sep 17 00:00:00 2001 From: Toshi MARUYAMA Date: Wed, 16 Feb 2011 01:14:34 +0000 Subject: [PATCH] scm: mercurial: add "hgtarget" method (#4455). Abstract adapter shell quotes paths. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@4840 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- lib/redmine/scm/adapters/mercurial_adapter.rb | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/redmine/scm/adapters/mercurial_adapter.rb b/lib/redmine/scm/adapters/mercurial_adapter.rb index 17afa674f..c0b879a91 100644 --- a/lib/redmine/scm/adapters/mercurial_adapter.rb +++ b/lib/redmine/scm/adapters/mercurial_adapter.rb @@ -251,6 +251,12 @@ module Redmine rev end private :hgrev + + def hgtarget(path) + path ||= '' + root_url + '/' + without_leading_slash(path) + end + private :hgtarget end end end