can't you do like rm -rf the directory that is going to be used, mv the tarball to the directory tar -(j/z)xvf (file name) rm the tarball // not necessary
i think that's about it.. On Tue, Oct 19, 2010 at 3:43 PM, Ramesh Dash <[email protected]> wrote: > Hi, > i need for bash shell script for this.. > > Regds > Ramesh > > > > On Tue, Oct 19, 2010 at 6:58 PM, Mohammad AbuShady > <[email protected]>wrote: > >> you didn't specify if you want it a linux bash script or a windows batch >> file >> >> On Tue, Oct 19, 2010 at 1:59 PM, Ramesh Dash <[email protected]>wrote: >> >>> i need to write a customized restore script to restore the disk files >>> from a tarball. >>> >>> The script should be like this: >>> >>> It should take two *arguments*; (1) the location of the tarball, and (2) >>> the location where to restore the tarball. >>> >>> The *behavior of the script *should be like: it must *restore all the >>> files/directories that are in the tarball* and it should *delete all the >>> other files/directories on the disk which are not *in the tarball. >>> >>> >>> Regds >>> Ramesh >>> >>> -- >>> You received this message because you are subscribed to the Google Groups >>> "Computer Tech Support" group. >>> To post to this group, send email to >>> [email protected]. >>> To unsubscribe from this group, send email to >>> [email protected]<computer-tech-support%[email protected]> >>> . >>> For more options, visit this group at >>> http://groups.google.com/group/computer-tech-support?hl=en. >>> >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Computer Tech Support" group. >> To post to this group, send email to >> [email protected]. >> To unsubscribe from this group, send email to >> [email protected]<computer-tech-support%[email protected]> >> . >> For more options, visit this group at >> http://groups.google.com/group/computer-tech-support?hl=en. >> > > -- > You received this message because you are subscribed to the Google Groups > "Computer Tech Support" group. > To post to this group, send email to > [email protected]. > To unsubscribe from this group, send email to > [email protected]<computer-tech-support%[email protected]> > . > For more options, visit this group at > http://groups.google.com/group/computer-tech-support?hl=en. > -- You received this message because you are subscribed to the Google Groups "Computer Tech Support" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/computer-tech-support?hl=en.
