зеркало из https://github.com/softlandia/cpd.git
v0.5.1 + NewReader
This commit is contained in:
Родитель
bd0131eb67
Коммит
8221c54f59
|
@ -5,13 +5,14 @@
|
|||
tohex -- simple program using cpd to encode the input string to the specified encoding and return the string from the hexadecimal code of the received runes
|
||||
|
||||
sample:
|
||||
>tohex Hi utf-16le
|
||||
>"\x48\x0\x69\x0"
|
||||
|
||||
>tohex аб-ёя utf16le
|
||||
>"\x30\x4\x31\x4\x2D\x0\x51\x4\x4F\x4"
|
||||
>tohex Hi utf-16le
|
||||
>"\x48\x0\x69\x0"
|
||||
|
||||
>tohex.exe аб-ёя win1251 >r.txt
|
||||
>"\xE0\xE1\x2D\xB8\xFF"
|
||||
>tohex аб-ёя utf16le
|
||||
>"\x30\x4\x31\x4\x2D\x0\x51\x4\x4F\x4"
|
||||
|
||||
>tohex.exe аб-ёя win1251 >r.txt
|
||||
>"\xE0\xE1\x2D\xB8\xFF"
|
||||
|
||||
the result string is convenient to use in the Golang code
|
Загрузка…
Ссылка в новой задаче