summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorEric Davis <edavis@littlestreamsoftware.com>2010-09-26 19:07:46 +0000
committerEric Davis <edavis@littlestreamsoftware.com>2010-09-26 19:07:46 +0000
commitbd511194607b33cf504de11f0a70c71cd6898192 (patch)
tree89e8d18ce9f1ddcce478a12c5b253a54c79eb6a3 /lib
parent319849caf8d269df386c01991b73a204db1018f5 (diff)
downloadredmine-bd511194607b33cf504de11f0a70c71cd6898192.tar.gz
redmine-bd511194607b33cf504de11f0a70c71cd6898192.zip
Support spaces in the files or directories in the git adapter. #6054
Contributed by Felix Schäfer git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@4188 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'lib')
-rw-r--r--lib/redmine/scm/adapters/git_adapter.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/redmine/scm/adapters/git_adapter.rb b/lib/redmine/scm/adapters/git_adapter.rb
index 9a79bbb07..f455a57f5 100644
--- a/lib/redmine/scm/adapters/git_adapter.rb
+++ b/lib/redmine/scm/adapters/git_adapter.rb
@@ -88,7 +88,7 @@ module Redmine
return nil if path.nil?
cmd = "#{GIT_BIN} --git-dir #{target('')} log --date=iso --pretty=fuller --no-merges -n 1 "
cmd << " #{shell_quote rev} " if rev
- cmd << "-- #{path} " unless path.empty?
+ cmd << "-- #{shell_quote path} " unless path.empty?
shellout(cmd) do |io|
begin
id = io.gets.split[1]
@@ -121,7 +121,7 @@ module Redmine
cmd << "#{shell_quote(identifier_from + '..')}" if identifier_from
cmd << "#{shell_quote identifier_to}" if identifier_to
cmd << " --since=#{shell_quote(options[:since].strftime("%Y-%m-%d %H:%M:%S"))}" if options[:since]
- cmd << " -- #{path}" if path && !path.empty?
+ cmd << " -- #{shell_quote path}" if path && !path.empty?
shellout(cmd) do |io|
files=[]