I'm relatively new to Linux, so forgive me if this is a silly question

I know that in windows's command prompt, if you change directories, you can then autocomplete/scan files within that folder by using the tab key, thus saving you time typing out the file name.

is there anything similar to this in linux ubuntu 14.04's terminal? so that i dont need to find the file outside of the terminal and then type it into the terminal.

thanks in advance


In linux there is also Tab complete. It does not cycle through the files tho. if you press tab twice, it will give you a list that matches what you have typed so far. ie.

$:/etc$ ls o *tab * tab*

odbc.ini odbcinst.ini opt/ os-release

$:/etc$ ls o


As an addition to grag42's answer;

Not sure if you understood, but a single tab completes it;

$:/etc$ ls o *tab * tab*

odbc.ini odbcinst.ini opt/ os-release

$:/etc$ ls os *tab*
$:/etc$ ls os-release

This also works for commands, and for some commands it even works as an argument autocomplete (for branchnames in git for example)

  • 1
    If you have an addition, please propose it as an edit. Half-answers are not answers. – TheWanderer Dec 10 '15 at 2:13
  • It didn't feel right to edit someone else's (marked) answer, and this markup didn't fit in a comment thus I went with this. Should I edit existing answers in the future? – Rob Quist Dec 10 '15 at 14:02
  • Always. That's the main reason it's there. Fixing only grammar and spelling is generally discouraged unless content is also added, or it's made easier to read. – TheWanderer Dec 10 '15 at 15:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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