DaemonForums  

Go Back   DaemonForums > FreeBSD > FreeBSD General

FreeBSD General Other questions regarding FreeBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 6th July 2011
sputnik's Avatar
sputnik sputnik is offline
Port Guard
 
Join Date: Mar 2009
Posts: 23
Thanked 0 Times in 0 Posts
Default no colors if starting screen in detached mode

Hi,

there's no colors in my screen if i'm reattaching to session which was started with -d -m, e.g. screen -d -m mc.
This is only happening on freebsd. How do i start screen in detached mode but with colors?
Reply With Quote
  #2   (View Single Post)  
Old 6th July 2011
Carpetsmoker's Avatar
Carpetsmoker Carpetsmoker is offline
Real Name: Martin
Old man from scene 24
 
Join Date: Apr 2008
Location: Eindhoven, Netherlands
Posts: 2,080
Thanked 198 Times in 156 Posts
Default

Which terminal emulator are you using and what is the value of your $TERM environment variable?
__________________
UNIX was not designed to stop you from doing stupid things, because that would also stop you from doing clever things.
Reply With Quote
  #3   (View Single Post)  
Old 6th July 2011
sputnik's Avatar
sputnik sputnik is offline
Port Guard
 
Join Date: Mar 2009
Posts: 23
Thanked 0 Times in 0 Posts
Default

xterm
Reply With Quote
  #4   (View Single Post)  
Old 6th July 2011
phoenix's Avatar
phoenix phoenix is offline
Risen from the ashes
 
Join Date: May 2008
Posts: 699
Thanked 90 Times in 81 Posts
Default

Screen apparently does some horrible TERM mangling and breaks a lot of colour-based terminals. There's a thread about this on one of the freebsd-stable@ mailing lists last month with some in-depth analysis of just how crappy screen's TERM handling really is (Subject: "csh Cannot open /etc/termcap after starting "screen"")

If you want a good, solid, working, non-TERM-mangling multiplexer, which much nicer default features than screen, then switch to tmux.
__________________
Freddie

Help for FreeBSD: Handbook, FAQ, man pages, mailing lists.
Reply With Quote
  #5   (View Single Post)  
Old 6th July 2011
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Helpful companion
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Thanked 193 Times in 184 Posts
Default

+1 for switching to tmux.
Reply With Quote
  #6   (View Single Post)  
Old 6th July 2011
sputnik's Avatar
sputnik sputnik is offline
Port Guard
 
Join Date: Mar 2009
Posts: 23
Thanked 0 Times in 0 Posts
Default

Everyone says 'switch to tmux', yeah, yeah, i know, tmux is better and so on, but i still wanna use screen and i'm sure there must be a way to start it without broking those colors. Everything's fine with openbsd or centos, this terminal issue only occur on freebsd...
Reply With Quote
  #7   (View Single Post)  
Old 7th July 2011
Carpetsmoker's Avatar
Carpetsmoker Carpetsmoker is offline
Real Name: Martin
Old man from scene 24
 
Join Date: Apr 2008
Location: Eindhoven, Netherlands
Posts: 2,080
Thanked 198 Times in 156 Posts
Default

What is the value of your $TERM environment variable in screen?

you can get this with: % echo $TERM
__________________
UNIX was not designed to stop you from doing stupid things, because that would also stop you from doing clever things.
Reply With Quote
  #8   (View Single Post)  
Old 7th July 2011
Oko's Avatar
Oko Oko is offline
Fsck Surgeon
 
Join Date: May 2008
Location: Kosovo, Serbia
Posts: 800
Thanked 36 Times in 32 Posts
Default

Code:
$ more .profile|grep TERM=
TERM=xterm-color
Reply With Quote
  #9   (View Single Post)  
Old 7th July 2011
Carpetsmoker's Avatar
Carpetsmoker Carpetsmoker is offline
Real Name: Martin
Old man from scene 24
 
Join Date: Apr 2008
Location: Eindhoven, Netherlands
Posts: 2,080
Thanked 198 Times in 156 Posts
Default

Quote:
Originally Posted by Oko View Post
Code:
$ more .profile|grep TERM=
TERM=xterm-color
This assumes you're a) Using some form of bourne shell, b) You're using ~/.profile to set it up and c) That the TERM isn't modified afterwards in another file or by an application (such as screen).
__________________
UNIX was not designed to stop you from doing stupid things, because that would also stop you from doing clever things.
Reply With Quote
Old 7th July 2011
Oko's Avatar
Oko Oko is offline
Fsck Surgeon
 
Join Date: May 2008
Location: Kosovo, Serbia
Posts: 800
Thanked 36 Times in 32 Posts
Default

Quote:
Originally Posted by Carpetsmoker View Post
This assumes you're a) Using some form of bourne shell, b) You're using ~/.profile to set it up and c) That the TERM isn't modified afterwards in another file or by an application (such as screen).
I apologize to everyone for that post. My fingers were faster than the brain. I have not read original thread carefully. I thought he was asking for the colors in the shell. To answer your question. I use

Code:
$ echo $SHELL
/bin/ksh
Yes, I use .profile to set my preferences. I do use tmux and I can see the colors.
Reply With Quote
Reply

Thread Tools
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
vsftpd not starting map7 FreeBSD Ports and Packages 1 10th June 2010 09:51 AM
change screen saver in text mode mfaridi FreeBSD General 2 29th October 2008 05:14 AM
mirror device detached on large file copy lil_elvis2000 FreeBSD General 24 27th June 2008 02:56 PM
Samba NOT STARTING pcfxer FreeBSD General 11 13th May 2008 09:29 AM


All times are GMT. The time now is 01:38 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick