ArchLinux decompression zip garbled has been resolved

Source: Internet
Author: User

Using Zip to extract files under ArchLinux has always been a headache for me.

Every time I received a classmate sent or downloaded from Windows compressed ZIP files, I opened are garbled, has not been a good solution.

The reason everyone knows: when compressing a file under Windows, it is compressed by the system's default encoding (gbk,gb18030), and the zip file does not have the encoded format, so when it is uncompressed, it is decompressed using the system default format (UTF-8). Encoding format is different, so there will be garbled.

Even if the data are said to be not reliable, what unzip-o, but it seems that the version of the-O option has long gone or how, anyway, is not used, and what the so-called solutions are copied to each other to copy the solution, in fact, those Bo master estimate there is no personal. Today finally can not help, ruthless under the heart to check an afternoon, try all kinds of methods, what 7z ah like all use, finally decided to give up. At this time, my efforts may have touched me, so the miracle appeared, on the order-

Unzip Xxx.zip

First Use this command to extract xxx.zip, assuming that the extracted file is xxx.

convmv-f gbk-t UTF8--notest xxx

This command is for file xxx to be converted from GBK encoding to UTF8 encoding, if not added--notest only preview instead of true conversion.

Hands-on practice, absolutely true, easy to use. (The script immediately extracted and transcoded more than 30 zip packets, but 4 failed, transcoding was unsuccessful.) The reason for the failure is that the files extracted from these zip packages are already UTF8 encoded, so they can no longer be converted to UTF8 encoding. But overall, the success rate is still very reliable!



ArchLinux decompression zip garbled has been resolved

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.