Bash: the tab key and auto-completion

I'm trying to figure out how to type an actual tab character on the Bash command line.

Bash used TAB as they key for an auto-completion function.  

When I'm trying to write sed scripts on the command-line, I cannot get a tab character typed into the script.

I'd be willing to learn how to turn off auto-completion, but it would be better to still have auto-completion and also be able to type the tab character.

thanks.
LVL 1
jcoman777Asked:
Who is Participating?
 
dtkernsCommented:
preceed your tab with a ctrl-V
0
 
leflonCommented:
Hi jcoman777,

if you need to include a TAB char in your sed statement you should use the \t escape sequence in the place of the TAB.

hth
leflon
0
 
jcoman777Author Commented:
I don't know what version of sed I have, but \t does not work.  I found a couple sources online that warned that \t would not work.

ctrl-v then TAB does work!  thanks!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.