Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

When I launch terminal, it looks fine. Black text on a white background. BUT when I run a command that requires the screen to scroll, it turns to white text on a white background. I have to triple-click to select-all in order to see the text. I use terminal all the time, so this is super annoying. Any ideas how I can fix it?

share|improve this question

Try piping your output through less.

$ command | less

You get the bonus of being able to page the output, and less might ignore the color control codes being sent by the program.

share|improve this answer
I can't do that because a build script runs the command, and the build is not interactive. Gotta just let it scroll. Plus, I need to see the output in case there are any errors. Thanks for the tip, though! – lo_fye Aug 20 '09 at 2:56
Piping through some sort of filter is the best approach when feasible. I don’t understand from the description why this wouldn’t be possible, especially because the build is not interactive. I would expect you to not be able to use a filter if the build was interactive. Other useful filtering commands for this are cat -v (which converts control characters into visible sequences of non-control characters) and tee to split the output so you can view it in the terminal and record it to a file, for example. Also, you could redirect to a file and view it in another terminal with tail. – Chris Page May 3 '12 at 6:38

Try trashing the preferences file:

com.Apple.Terminal.plist in Users//Library/Preferences

Also, can you give an example of a command that causes this behaviour?

share|improve this answer
Sadly, trashing the plist didn't help :( The command I run is actually a build script using Phing, a PHP port of Apache Ant. The command "phing propel" re-creates a bunch of files. – lo_fye Aug 19 '09 at 15:22
Ah, and is that the only command that causes this behaviour? Because if it is (for example, man ifconfig produces a lot of output in a similar fashion i'm willing to bet) then it means that Phing is causing wonky output. Have you consulted their support team? – EvilChookie Aug 19 '09 at 15:24
man ifconfig produces nice black text on white background, but it doesn't scroll. The issue happens when the output causes the screen to scroll. That being said, I just tried: ls /* and it stayed black. So I guess it is a Phing thing. Weird. Unfortunately, as with so much PHP stuff, Phing has no support team beyond a Google Group. Thanks for your help. – lo_fye Aug 19 '09 at 15:34
No problems, I wish I could help further. I feel your pain regarding the PHP stuff. I haven't used Phing however. – EvilChookie Aug 19 '09 at 15:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .