LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   help information running off the screen with tar command (https://www.linuxquestions.org/questions/linux-newbie-8/help-information-running-off-the-screen-with-tar-command-4175430673/)

eBlip 10-05-2012 08:41 AM

help information running off the screen with tar command
 
hi ...im using tar command
typing tar filename.tar/bz2
and im getting old option f requires and argument
i type tar --help

the problem is the output of the help most of it runs off the screen and doesnt stop...like when using the function (man).
what can i do to stop it running of the screen so i can read what is going on ...and

what is wrong with my tar command
thanks

henrycoffin 10-05-2012 08:45 AM

Pipe the output of tar --help in to less so you can read it all

# tar --help | less

TobiSGD 10-05-2012 09:18 AM

You have to tell tar what it has to do. If you want to extract a file you have to give it the extract option -x and you have to tell that you want to extract a file, not the standard input, with the -f option. So your command should look like this:
Code:

tar -xf filename.tar.bz2

eBlip 10-05-2012 09:22 AM

thanks guys .... using the pipe less command piped the output of help through screen by screen ...and enabled me to look at the command structure..
i ended up doing the -tvf to see what was in there and then the -xf to extract...
thank again guys ...the linux crowd are so efficient and helpful..


All times are GMT -5. The time now is 09:54 AM.