diff options
author | Valery Sizov <valery@gitlab.com> | 2015-02-02 17:01:07 -0800 |
---|---|---|
committer | Valery Sizov <valery@gitlab.com> | 2015-02-05 12:50:34 -0800 |
commit | 33349dd54928a0b074b4ae3ebfabf214799fc085 (patch) | |
tree | 593a14d0f6df812410349f353e252e3a58d8cacd /lib/gitlab/import_formatter.rb | |
parent | 713bc152bde5396bb95a1555907bcd9a2847839d (diff) | |
download | gitlab-ce-33349dd54928a0b074b4ae3ebfabf214799fc085.tar.gz |
GitLab.com integration: refactoring
Diffstat (limited to 'lib/gitlab/import_formatter.rb')
-rw-r--r-- | lib/gitlab/import_formatter.rb | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/lib/gitlab/import_formatter.rb b/lib/gitlab/import_formatter.rb new file mode 100644 index 00000000000..a9283eaf2a5 --- /dev/null +++ b/lib/gitlab/import_formatter.rb @@ -0,0 +1,15 @@ +module Gitlab + class ImportFormatter + def comment_to_md(author, date, body) + "\n\n*By #{author} on #{date}*\n\n#{body}" + end + + def comments_header + "\n\n\n**Imported comments:**\n" + end + + def author_line(author, body) + "*Created by: #{author}*\n\n#{body}" + end + end +end
\ No newline at end of file |