trapias/TrelloExport

A bug when you export multi-byte character cards to markdown format

wukuan405 opened this issue · 8 comments

Bug report

when you export multi-byte character cards to markdown format, such as Japanese,
the characters will be wrong as following sample.
But the excel format is no problem.

Bug data sample

**Description:**
無料で、海外販売ができるネットショップ開業サービス。すでに国内ショップを運営されてる

Suggestion

you'd better check the encoding or utf configuration at the markdown format export parts.

@wukuan405 could you please provide a public board on which to test, or add some Japanese text to TrelloExport board at https://trello.com/b/MBnwUMwM/trelloexport ?

I see MacDown does render properly - don't know Japanese, but it looks like it does, correct?

istantanea_19_05_16__08_48

@wukuan405 also here it looks like to work correctly, here's your text pasted in editor:

無料で、海外販売ができるネットショップ開業サービス。すでに国内ショップを運営されてる

the right side is correct!

https://trello.com/c/JXcY0d28
here is the japanese test data, please try it.

@wukuan405 the exported file is UTF8 and I believe characters are correctly encoded, the only problem I see is the javascript code is not rendered, but that's because the proper markdown syntax for a code section should be used.

trelloexport_20160519163723_md_e_turms_-_software_for_event_freighting

trelloexport_20160519163723_md

You are right, but why the export of the markdown file could not be the readable characters.
I found following resources which might be valuable for you to check.
https://github.com/harisenbon/autokana
http://www.nishishi.com/javascript/2007/encodeuri.html
best regards,

@wukuan405 I'm looking into this issue. At the moment, the best solution I have is still to encode this way, so to avoid any error and be able to open (and read) both the produced .md and .html files, but it's true only special chars should be encoded in markdown, that is:

\  backslash 
`  backtick 
*  asterisk 
_  underscore 
{} curly braces 
[] square brackets 
() parentheses 
#  hash mark 
>  greater than 
+  plus sign 
-  minus sign (hyphen) 
.  dot 
!  exclamation mark

Will try to find a better solution!

@wukuan405 I got it, will commit a new release fixing the problem very soon