docdiff 0.6.7 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +69 -36
  3. data/README_ja.md +70 -37
  4. data/doc/example/docdiff.conf.example +3 -0
  5. data/doc/img/screenshot-html.png +0 -0
  6. data/doc/img/screenshot-tty-char.png +0 -0
  7. data/doc/img/screenshot-tty-digest-block.png +0 -0
  8. data/doc/img/screenshot-tty-digest-license-block.png +0 -0
  9. data/doc/img/screenshot-tty-digest-license.png +0 -0
  10. data/doc/img/screenshot-tty-digest.png +0 -0
  11. data/doc/img/screenshot-tty-en-ja.png +0 -0
  12. data/doc/img/screenshot-tty-manued.png +0 -0
  13. data/doc/img/screenshot-tty-wdiff.png +0 -0
  14. data/doc/img/screenshot-tty-word-char.png +0 -0
  15. data/doc/man/docdiff.adoc +3 -3
  16. data/doc/news.md +11 -0
  17. data/docdiff.gemspec +1 -1
  18. data/lib/doc_diff.rb +5 -5
  19. data/lib/docdiff/charstring.rb +36 -40
  20. data/lib/docdiff/cli.rb +23 -10
  21. data/lib/docdiff/document.rb +44 -44
  22. data/lib/docdiff/encoding/en_ascii.rb +4 -4
  23. data/lib/docdiff/version.rb +1 -1
  24. data/lib/docdiff/view.rb +27 -13
  25. data/test/charstring_test.rb +221 -221
  26. data/test/cli_test.rb +12 -12
  27. data/test/document_test.rb +223 -223
  28. data/test/fixture/humpty_dumpty_01_en.txt +4 -0
  29. data/test/fixture/humpty_dumpty_01_ja.txt +4 -0
  30. data/test/fixture/{humpty_dumpty01_ascii_lf.txt → humpty_dumpty_02_en.txt} +2 -2
  31. data/test/fixture/humpty_dumpty_02_ja.txt +4 -0
  32. data/test/view_test.rb +38 -31
  33. metadata +26 -14
  34. data/test/fixture/humpty_dumpty02_ascii_lf.txt +0 -4
  35. /data/doc/img/{screenshot-format-html-digest-firefox.png → old/screenshot-format-html-digest-firefox.png} +0 -0
  36. /data/doc/img/{screenshot-format-html-firefox.png → old/screenshot-format-html-firefox.png} +0 -0
  37. /data/doc/img/{screenshot-format-tty-cmdexe-en.png → old/screenshot-format-tty-cmdexe-en.png} +0 -0
  38. /data/doc/img/{screenshot-format-tty-cmdexe-ja.png → old/screenshot-format-tty-cmdexe-ja.png} +0 -0
  39. /data/doc/img/{screenshot-format-tty-rxvtunicode-en.png → old/screenshot-format-tty-rxvtunicode-en.png} +0 -0
  40. /data/doc/img/{screenshot-format-tty-rxvtunicode-ja.png → old/screenshot-format-tty-rxvtunicode-ja.png} +0 -0
  41. /data/doc/img/{screenshot-format-tty-xterm-en.png → old/screenshot-format-tty-xterm-en.png} +0 -0
  42. /data/doc/img/{screenshot-format-tty-xterm-ja.png → old/screenshot-format-tty-xterm-ja.png} +0 -0
  43. /data/doc/img/{screenshot-resolution-linewordchar-xterm.png → old/screenshot-resolution-linewordchar-xterm.png} +0 -0
data/test/cli_test.rb CHANGED
@@ -221,18 +221,18 @@ class TestCLI < Test::Unit::TestCase
221
221
  def test_cli_digest
222
222
  expected = <<~EOS
223
223
  ----
224
- 1,1
224
+ L1, L1
225
225
  Hello, my name is [-Watanabe.-]{+matz.+}
226
226
 
227
227
  ----
228
- (2),2
228
+ (L2), L2
229
229
 
230
230
  {+It's me who has created Ruby. +}I am#{" "}
231
231
  ----
232
- 2,2
232
+ L2, L2
233
233
  I am [-just another -]{+a +}Ruby#{" "}
234
234
  ----
235
- 2,2
235
+ L2, L2
236
236
  Ruby [-porter.-]{+hacker.+}
237
237
 
238
238
  ----
@@ -246,18 +246,18 @@ class TestCLI < Test::Unit::TestCase
246
246
  def test_cli_display_inline
247
247
  expected = <<~EOS
248
248
  ----
249
- 1,1
249
+ L1, L1
250
250
  Hello, my name is [-Watanabe.-]{+matz.+}
251
251
 
252
252
  ----
253
- (2),2
253
+ (L2), L2
254
254
 
255
255
  {+It's me who has created Ruby. +}I am#{" "}
256
256
  ----
257
- 2,2
257
+ L2, L2
258
258
  I am [-just another -]{+a +}Ruby#{" "}
259
259
  ----
260
- 2,2
260
+ L2, L2
261
261
  Ruby [-porter.-]{+hacker.+}
262
262
 
263
263
  ----
@@ -271,23 +271,23 @@ class TestCLI < Test::Unit::TestCase
271
271
  def test_cli_display_block
272
272
  expected = <<~EOS
273
273
  ----
274
- 1,1
274
+ L1, L1
275
275
  Hello, my name is [-Watanabe.-]
276
276
 
277
277
  Hello, my name is {+matz.+}
278
278
 
279
279
  ----
280
- (2),2
280
+ (L2), L2
281
281
 
282
282
  I am#{" "}
283
283
 
284
284
  {+It's me who has created Ruby. +}I am#{" "}
285
285
  ----
286
- 2,2
286
+ L2, L2
287
287
  I am [-just another -]Ruby#{" "}
288
288
  I am {+a +}Ruby#{" "}
289
289
  ----
290
- 2,2
290
+ L2, L2
291
291
  Ruby [-porter.-]
292
292
 
293
293
  Ruby {+hacker.+}