LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.

Notices


Reply
  Search this Thread
Old 01-07-2021, 02:43 PM   #1
derguteweka
Member
 
Registered: Sep 2018
Distribution: BLFS
Posts: 74

Rep: Reputation: 21
Question LFS10: strange characters in vim via ssh


Moin,

On brand new LFS10; facing strange problem:

If i open file with vi(m) and syntax highlighting is on, strange numbers/characters appear in the terminal, example:
Code:
set 5:81mruler
the same line when syntax highlighting is switched off in vim looks ok:
Code:
set ruler
But this happens only, if i do this via ssh connection. On the machine itself it's OK with/without syntax highlighting.
Also colored ls output and cacafire via ssh are OK.

Somehow the escape sequences for coloring might get misinterpreted i guess, but i've never seen something like this before.
Happens with the 8.2.something vim used in LFS10, but also with vim74 i just installed because on versions >7.999 vim tends to do lots of rather strange things im my opinion.
But this time the Version >8 doesnt seem to be the problem, but the ssh connection?

Any advice would be welcome...

Gruss
WK
 
Old 01-09-2021, 06:53 AM   #2
shruggy
Senior Member
 
Registered: Mar 2020
Posts: 3,678

Rep: Reputation: Disabled
Code:
tput setaf 1;echo foo;tput sgr0
Does the line above work as intended? What is your $TERM when you log in via ssh? Is it different when you log in locally?
 
1 members found this post helpful.
Old 01-09-2021, 07:44 AM   #3
derguteweka
Member
 
Registered: Sep 2018
Distribution: BLFS
Posts: 74

Original Poster
Rep: Reputation: 21
Moin,

Quote:
Originally Posted by shruggy View Post
Code:
tput setaf 1;echo foo;tput sgr0
Does the line above work as intended?
Prints foo in red - i guess, this was the intended behaviour.

Quote:
Originally Posted by shruggy View Post
What is your $TERM when you log in via ssh? Is it different when you log in locally?
Up to now, i never set it on purpose. Seems to be always set to "xterm-256color", no matter if local or remote ssh (also on connecting to older LFSses via ssh, where it worked for years w/o hassle and still does).

But when connecting to the LFS10 machine via ssh and setting $TERM to e.g. "linux" or "xterm", vim looks OK.
So this will solve the symptoms of my problem, but the question still is: What has changed there?

Gruss
WK
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Fedora shows 'man vim' but when execute 'vim' got "bash: vim: command not found..." ? flash_os Linux - Newbie 19 01-03-2015 11:56 PM
Strange vim startup behavior when accessed via cygwin ssh nicklaszlo Linux - Desktop 4 03-13-2010 10:49 PM
Switching from vim to vim -g from inside vim iDragoon Linux - Software 4 05-15-2009 11:46 AM
Editor comparison: vim VS vim-lite, Cleaning vim Ruler2112 *BSD 4 04-13-2009 04:26 PM
VIM Users: Do you use VIM via console or gui? JMJ_coder Linux - General 48 04-16-2008 03:12 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 12:28 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration