プロジェクト

全般

プロフィール

Vote #76364

完了

Newlines stripped from CVS commit messages

Admin Redmine さんが約4年前に追加. 約4年前に更新.

ステータス:
Closed
優先度:
通常
担当者:
-
カテゴリ:
SCM_3
対象バージョン:
開始日:
2022/05/09
期日:
進捗率:

0%

予定工数:
category_id:
3
version_id:
97
issue_org_id:
19835
author_id:
17498
assigned_to_id:
1
comments:
3
status_id:
5
tracker_id:
1
plus1:
0
affected_version:
closed_on:
affected_version_id:
96
ステータス-->[Closed]

説明

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.
--------------------------------------------------------------------------------

--------------------------------------------------------------------------------

Admin Redmine さんが約4年前に更新

  • カテゴリSCM_3 にセット
  • 対象バージョン3.0.4_97 にセット

他の形式にエクスポート: Atom PDF

いいね!0
いいね!0