Vote #76364
完了Newlines stripped from CVS commit messages
0%
説明
I noticed this in 3.0.3 but I think the issue was introduced with "this":https://github.com/redmine/redmine/commit/2d1866d966d94c688f9cb87c5bf3f096dffac844#diff-d761ec446fc6d854f73974c4206a7e40R171 change.
This is on Linux with the 3.0.3 tarball, rails 4.2.1, ruby 2.2.2-p95, CVS 1.12.13 and mysql 5.6.24 with the msyql2 adapter.
A quick fix that seems to work is:
diff --git a/lib/redmine/scm/adapters/cvs_adapter.rb b/lib/redmine/scm/adapters/cvs_adapter.rb
index 92be438..8aceca6 100644
--- a/lib/redmine/scm/adapters/cvs_adapter.rb
+++ b/lib/redmine/scm/adapters/cvs_adapter.rb
@@ -260,7 +260,7 @@ module Redmine
# version.line_minus = 0
# end
else
- commit_log << line unless line =~ /^\*\*\* empty log message \*\*\*/
+ commit_log << line << "\n" unless line =~ /^\*\*\* empty log message \*\*\*/
end
end
end
but I'm not sure if something should be done with the encoding.
journals
Original change is r13442.
<pre><code class="diff">
Index: cvs_adapter.rb
===================================================================
--- cvs_adapter.rb (revision 13441)
+++ cvs_adapter.rb (revision 13442)
@@ -168,6 +168,7 @@
file_state = nil
branch_map = nil
io.each_line() do |line|
+ line = line.strip
if state != "revision" && /^#{ENDLOG}/ =~ line
commit_log = String.new
revision = nil
</code></pre>
I think we can revert this "line = line.strip" addition because Redmine 3.0 does not support JRuby.
--------------------------------------------------------------------------------
Change reverted.
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------