Topic "Cyrillic locale"

Author Message
ks
[View user's profile]
Donor
Joined: 2008-09-18
Posts: 77
Location: Moscow
Is WinWCP capable of parsing output of 'ls -la' on a system with Cyrillic locale? That's when the first line of ls output says not 'total n' but 'итого n' (same in Russian) plus the word is UTF encoded?
Advertisements
ks
[View user's profile]
Donor
Joined: 2008-09-18
Posts: 77
Location: Moscow
I guess if I check the "Clear national variables" option that will do the trick?
martin◆
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 26890
Location: Prague, Czechia
ks wrote:
I guess if I check the "Clear national variables" option that will do the trick?

Yes, it should.
_________________
Martin Prikryl
Guest




Looks like something broken in "Clear national variables" option.
I try to connect to server with ru_RU.UTF-8 locale and can't see directory listing with error
"Unexpected directory listing line" where I can see, that timestamp of directory/files are in
national (cyrillic) letters. I try to reset locale in terminal window:

/usr/home/roman$ locale
LANG=ru_RU.UTF-8
LC_CTYPE="ru_RU.UTF-8"
LC_COLLATE="ru_RU.UTF-8"
LC_TIME="ru_RU.UTF-8"
LC_NUMERIC="ru_RU.UTF-8"
LC_MONETARY="ru_RU.UTF-8"
LC_MESSAGES="ru_RU.UTF-8"
LC_ALL=
/usr/home/roman$ setenv LANG en_US.UTF-8
/usr/home/roman$ locale
LANG=en_US.UTF-8
LC_CTYPE="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_ALL=

After that I can see directory/files listing.

shell:
/usr/home/roman$ ps
PID TT STAT TIME COMMAND
73109 0 Ss+ 0:00,07 -csh (csh)
martin◆
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 26890
Location: Prague, Czechia
Please attach a full session log file showing the problem (using the latest version of WinSCP).

To generate the session log file, enable logging, log in to your server and do the operation and only the operation that causes the error. Submit the log with your post as an attachment. Note that passwords and passphrases not stored in the log. You may want to remove other data you consider sensitive though, such as host names, IP addresses, account names or file names (unless they are relevant to the problem). If you do not want to post the log publicly, you can mark the attachment as private.
Guest




Hello, Martin. Thanks for looking at this issue.

There is session log.
192.168.70.101.log (53.23 KB) Private file

Description: session log

Guest




Maybe this can help you understand problem:

roman@solution:~ % echo $PAGER
more
roman@solution:~ % unset PAGER
roman@solution:~ % echo $PAGER
more
roman@solution:~ % setenv PAGER
roman@solution:~ % echo $PAGER

roman@solution:~ %
martin◆
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 26890
Location: Prague, Czechia
Anonymous wrote:
Maybe this can help you understand problem:

roman@solution:~ % echo $PAGER
more
roman@solution:~ % unset PAGER
roman@solution:~ % echo $PAGER
more
roman@solution:~ % setenv PAGER
roman@solution:~ % echo $PAGER

roman@solution:~ %

Do you suggest that the unset does not work on your server?
Guest




martin wrote:
Do you suggest that the unset does not work on your server?


https://man.openbsd.org/csh
Quote:

Variable substitution
The shell maintains a list of variables, each of which has as value a
list of zero or more words. The values of shell variables can be dis-
played and changed with the set and unset commands. The system main-
tains its own list of ``environment'' variables. These can be dis-
played and changed with printenv, setenv and unsetenv.


As I understand, LANG variable can be operated via setenv/unsetenv command only.
Guest




Maybe just add new "Shell" type ("csh" as example), which will be use unsetenv for "Clear national variables" procedure?
martin◆
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 26890
Location: Prague, Czechia
Anonymous wrote:
Maybe just add new "Shell" type ("csh" as example), which will be use unsetenv for "Clear national variables" procedure?

Well, actually you should use configure the bash for WinSCP sessions (if your default/preferred shell is not bash-compatible).
https://winscp.net/eng/docs/requirements#scp
Guest




martin wrote:
Well, actually you should use configure the bash for WinSCP sessions (if your default/preferred shell is not bash-compatible).
https://winscp.net/eng/docs/requirements#scp


Quote:
The bash shell is recommended for working with WinSCP. If your default shell does not work with WinSCP, you can specify another shell. Typing the full path (e.g. /bin/bash or /usr/local/bin/bash) is recommended.


It develops that I can put any symbol as shell! So, "/bin/sh" works very well for me. Thanks for help, Martin!
Advertisements

You can post new topics in this forum

Search

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License