To see if a file exists in a tar archive, you could use the t command. For example to see if the file data/files/myfile exists in the tarfile file.tar you could do this:
Code:
tar tvf file.far data/files/myfile
You might also employ grep to look for any files whose name contains the text "myfile" (note grep is case sensitive unless you specify the -i option):
Code:
tar tvf file.tar |grep myfile
You can delete files from a tar archive using the --delete option, but this is not for use with tapes - just if you are using tar files as a container format (e.g. for distribution of groups of files).
I recommend you take a look at the
tar tutorial for more information, not to mention the manual and infotex pages which most likely are installed on your linux system. To access these, just type "man tar", and "info tar".