Re: non ascii character

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Patrick Dupre via users wrote:
> I used
> grep -axv '.*' 
>  
> Seems OK

You might want to check what 'file -i /path/to/your/file'
reports.  Running a quick test, it seems gedit (and the
newer Gnome text editor app) both do rather poorly when it
comes to opening files which are in another charset.

    $ echo 'naïve' | iconv -t ISO-8859-1 - >/tmp/test
    $ file -i /tmp/test
    /tmp/test: text/plain; charset=iso-8859-1

Opening this file with gedit give a big warning, but (at
least in my case) it does provide the option to select a
character set and retry.  I changed the drop-down selection
from UTF-8 to ISO-8859-15 and then it opened the file
correctly.

You can use 'iconv' to change the charset encoding of the
files, among other methods (see the man page for usage and
some examples).

That might be worth doing if you want to use gedit, which
doesn't seem to support a non-UTF-8 world very well (which
seems like a bizarre limitation for a text editor these
days).

Opening the same file with `vim` does exactly what I'd
expect.  Though reinstalling the default terminal editor,
nano, it also fails to display the contents correctly.  So
perhaps I'm just spoiled that vim does automatic conversions
quite well.

It is definitely nicer to just work with UTF-8 these days,
as nearly everything plays well with it and it is more than
capable of displaying almost any characters needed by
various cultures and languages.

-- 
Todd

Attachment: signature.asc
Description: PGP signature

-- 
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/users@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue
[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux