Sign up ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Is there a way to get colored output when using tab completion in a terminal? My colors are fine everywhere else so I know that I've enabled a color terminal successfully.

Using bash in Ubuntu (10.10).

share|improve this question
How do you specify a "colored output when using tab completion"? – slhck Feb 27 '11 at 19:51

1 Answer 1

up vote 7 down vote accepted

There's no facility within Bash to color output during completion as there is in fish and zsh. One could write completion functions that output color control sequences, but you'd have to maintain copies of the proposed completions with and without color codes or strip the out when the user makes a selection since Bash uses the selection directly normally and the color codes would get in the way.

If this is an important feature for you, I would recommend that you consider using zsh.

share|improve this answer
I'll look into zsh, but at this point I fear I am too lazy to switch to a different shell :) Thanks for the clarification! – Ryan Feb 27 '11 at 20:20
@Ryan: Zsh is quite compatible with Bash. You would probably find the switch to be fairly easy. It has a lot of powerful features that Bash doesn't have (or you have to use external utilities for). There are only a few things that are significantly different in the basics. An example is that array indexes are one-based instead of zero-based, but there's a setting that affects that. I only use zsh occasionally, though. – Dennis Williamson Feb 27 '11 at 20:30

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.