problems with vi/vim with fedora core 4
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Unix and Linux reviews > Red Hat support > Red Hat Topics > problems with vi/vim with fedora core 4




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    problems with vi/vim with fedora core 4  
Jean-Francois Ortolo


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-03-07 06:12 PM


Hi all

I got installed Fedora Core 4 a long time ago, then updated the
kernel recently with 'yum update kernel' from root, all went fine.

I had no problem with the vi editor before the kernel updating,
afterwards however, I was not able to write some no ascii characters,
even with the keys sequence 'Alt <number>' I was accustomed to.

I then udated vi/vim with: 'yum update vi-common', which was
successful and updated vi-extended too. The problem remains.

The need is to edit a php script which translates those special
characters, into ascii character, with plenty of: if($var == "<special
char>") $var = "<ascii char>";

The $TERM env variable is: "linux". Should I change that ?

Which is the proper way I should use to edit spécial characters in
vi/vim ?

Moreover, I got some little problems while alternating Edit mode and
Insert mode, but that's not disturbing too much.

Thank you very much for your help.

Best regards.

Jean Francois Ortolo





[ Post a follow-up to this message ]



    Re: problems with vi/vim with fedora core 4  
Jean-Francois Ortolo


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-03-07 06:12 PM

Addendum...

Here are the rpms on my system:

vim-common-6.3.086.fc4
vim-enhanced-6.3.086-0.fc4

Then, uname -a reports:

Linux ortolo.jeanfrancois.free.fr 2.6.17-1.2142 FC4 #1 <date> <hour>
EDT 2006 i686 athlon i386 GNU/Linux

Thank you very much for your help.

Best regards.

Jean Francois Ortolo





[ Post a follow-up to this message ]



    Re: problems with vi/vim with fedora core 4  
Scott Lurndal


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-03-07 06:12 PM

Jean-Francois Ortolo <ortolo.jeanfrancois.no_spam@free.fr.invalid> writes:
>
>Hi all
>
>   I got installed Fedora Core 4 a long time ago, then updated the
>kernel recently with 'yum update kernel' from root, all went fine.
>
>   I had no problem with the vi editor before the kernel updating,
>afterwards however, I was not able to write some no ascii characters,
>even with the keys sequence 'Alt <number>' I was accustomed to.
>
>   I then udated vi/vim with: 'yum update vi-common', which was
>successful and updated vi-extended too. The problem remains.
>
>   The need is to edit a php script which translates those special
>characters, into ascii character, with plenty of: if($var == "<special
>char>") $var = "<ascii char>";
>
>   The $TERM env variable is: "linux". Should I change that ?
>
>   Which is the proper way I should use to edit spécial characters in
>vi/vim ?
>
>   Moreover, I got some little problems while alternating Edit mode and
>Insert mode, but that's not disturbing too much.
>
>   Thank you very much for your help.
>
>   Best regards.
>
>   Jean Francois Ortolo

Check your LANG environment variable.   When in doubt, fall back to LANG=C.

also check the output of "env | grep LC_"

scott





[ Post a follow-up to this message ]



    Re: problems with vi/vim with fedora core 4  
Jean-Francois Ortolo


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-04-07 12:12 AM

Scott Lurndal wrote:
>
> Check your LANG environment variable.   When in doubt, fall back to LANG=C
.
>
> also check the output of "env | grep LC_"
>
> scott

Hi

Tried "fr", "fr_FR", then "fr_FR.UTF-8", then "C" for the $LANG
variable, as shown in the /ets/sysconfig/i18n config file.

Tried LC_ALL="fr" instead of LC_ALL=C as before, and LANG="fr" at the
same time.

For all this, I tried to edit a simple essai.txt empty file with vim,
wrote the é letter ( e acute ), then did a: 'od -c essai.txt'

It appears, that vi only edit in UTF mode, which is not correct for
PHP scripts editing.

I vaguely remember there was an advice about that in the FC5 ( or FC6
) docs.

With gedit editor, the special characters appear fine, but I don't
know the way to edit them. Same with emacs.

May I be allowed, to ask you to give me some indications for an
editor properly designed for this kind of tasks ?

Thank you very much for your help.

Best regards.

Jean Francois Ortolo





[ Post a follow-up to this message ]



    Re: problems with vi/vim with fedora core 4  
Jean-Francois Ortolo


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-04-07 12:12 AM

Hi sir

I deleted the addendum I wrote to the /etc/profile config file many
months ago, such that the LC_ALL env variable has no more value.

At the same time, I changed the /etc/sysconfig/i18n config file, with:

LANG="fr_FR"

So the whole system should properly be configured for the french
language, isn't it ?  Indeed, the system messages at the char screen, do
then appear in french... But accentutated letters, such as e acute ( é
), don't appear at all on the screen.

At the same time, while editing a text file properly written with
special characters, those special characters don't appear at all on the
screen in vim.

As it's quite the same problem as the system messages one, I suspect
that the $TERM env variable, could be badly configured. The actual value
is: "linux".

I'm accustomed to the system messages problem, as described above,
and I didn't pay attention to it, for I encountered it first just after
the install process.

Might you say to me, where is this problem coming from ?

What is the $TERM variable proper value, in a french environment ?

Many thanks for your help.

Regards.

Jean Francois Ortolo





[ Post a follow-up to this message ]



    Re: problems with vi/vim with fedora core 4  
Jean-Francois Ortolo


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-04-07 12:12 PM

Hi sir

I removed the little addendum I made to the /etc/profile config file,
e.g. :

LC_ALL="C"
export LC_ALL

Afterwards, I did a: env| grep "LC_"  , which reports no value.

So the $LC_LOCALE variable has no value, though I'm in a french
environment.

Should I give any value to this variable, and if so, which value ?

May be:

LC_LOCALE="fr"  or
LC_LOCALE="fr_FR"

I definitely give to the $LANG variable, this value: "fr_FR", which
makes all system messages be in french.

I think testing both those values, for inquiry.

Many thanks for your help.

Jean Francois Ortolo





[ Post a follow-up to this message ]



    Re: problems with vi/vim with fedora core 4  
Jean-Francois Ortolo


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-04-07 12:12 PM

Scott Lurndal wrote:
>
> Check your LANG environment variable.   When in doubt, fall back to LANG=C
.
>
> also check the output of "env | grep LC_"
>
> scott


Hi sir

I'm in a french environment, so I give this value to the $LANG
variable: "fr_FR". In fact, I don't want the used characters set, be
unicode.

I tried this: env | grep "LC_" , which reports nothing: No LC_
variable has any value.

I know the LC_ variables, should be given values inside the
/etc/sysconfig/i18n config file. The only variable appearing in it, is:
LANG="fr_FR"

The three available values for $LANG are: "fr", "fr_FR", and
"fr_FR.UTF-8" , from the comment line at the end of the file.

I think I should set some LC_ variables, such as: LC_CTYPE,
LC_COLLATE, or LC_LOCALE, but whatever values could be available, being
assumed my environment is frenchy ?

Many thanks for your help.

Jean Ortolo





[ Post a follow-up to this message ]



    Re: problems with vi/vim with fedora core 4  
Jean-Francois Ortolo


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-06-07 12:13 AM

Hi

In fact, I returned to utf8, by setting those variables in the
/etc/sysconfig/i18n config file:

LANG="fr_FR.UTF-8"
LC_ALL="fr_FR.UTF-8"
CHARSET="8859-1"

..

And, while editing a text file with vim, I tape:

:lang fr_FR.ISO_8859-1

Then, the file is being edited in iso8859-1, not in utf8

The accentuated letters, whose ascii codes are below 256, either
appear all the same, in iso or utf8 mode. That's fine.

Hope this can help.

Jean-Francois Ortolo





[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 09:48 PM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register