It depends on the command used to create the tar archive. If
produces something like: ./filename or ./dir1/dir2/filename then if you use EXACTLY what tar tf showed, this will work - I picked one arbitrary name: ./filename
if tar tf shows some name of the file without a leading dot ex: /path/filename
Then the /path directory has to be writable by your process. And /path/filename should not exist because tar will overwrite it.
then try:
This User Gave Thanks to jim mcnamara For This Post:
Hello I am trying to append an incrimenting number to the end of each line I have it working with a temp file. But I want to do this without a temp file.
a=1
cat "file" | while read LINE
do
echo "$LINE, $a" >> filewithnumbers
a=`expr $a + 1`
... (4 Replies)
Hi,
I have been trying to shoot an email with the email body to be obtained from a file.
Can someone please help me with it..
I have been trying to use the MAILX commad for the same.
mailx -s "test email" -r sender@test.com < file.txt
but it sends the file as an attachment,while i... (3 Replies)
Hi Experts,
I have a requirement where i need to update the below items in file,
1. END TIME
2. PREV_STATUS
For the first time the PREV_status and end time of all job the job will be sysdate & NULL reply as below,
Session_name,Load Type,Frequency,Seesion End time,Prev_Status... (2 Replies)
Hi -
I am looking for a replacing a string in a in multiple *.sql files in directory with a new string without using a temporary file
Normally I can use sed command as below
for W in ls `FILE*.sql`
do
sed 's/OLD/NEW/g' $W > TEMPFILE.dat
mv TEMPFILE.dat $W
done
But Here in my... (9 Replies)
I am trying to run a script called install.sh as follows:
I get a jar file, and extract it using the command:
unzip filename.jar -D path/to/files
then I navigate to that directory where I extracted the files, and run the command:
sh install.sh
(where install.sh is one of the files... (12 Replies)
I've written the script below to merge only .txt files that exist in one directory into one huge .txt file and ignore other files with other extensions.
now the result is one huge .txt file with all the contents of other .txt files
how can i add a File Name as a comment before each file?
... (12 Replies)
If I have a script that is using
unrar e file.part1.rar
How does the script get the name of the extracted file if I don't know the extension of the file?
In my example the name would be file.***, but I wouldn't know the extension.
---------- Post updated at 05:13 PM ---------- Previous... (0 Replies)
hello guys
Please help me with the below issue
I have two files one base file another lookupfile
base file
abc-001
bcd-001
cde-001
Lookupfile
abc-001|11|12
abc-001|11|12
abc-001|11|12 (6 Replies)
Hi techies
I am trying to write a script which can give me a ATP of a job,
My idea is :
store a value in a temp variable, next script read the variable in next call of it and give me the diff of values which is ATP, as script is running every hours.
Can we do this in Shell Script.
If... (5 Replies)
I am trying to compare/confirm the output of an script using the perl below, which does execute. However I can not seem to print $1 and $2 in each line of the input separated by a tab in each line of the output. The input file is quite large so I have only included a portion, but the format is the... (0 Replies)
Discussion started by: cmccabe
0 Replies
LEARN ABOUT CENTOS
shape_tar
SHAPE_TAR(1) General Commands Manual SHAPE_TAR(1)NAME
shape_tar - shapeTools RMS bundle up subsystem in a tar or shar archive
SYNOPSIS
shape tar[VERSIONS=<version_selection_rule>] [ARCHIVE=<filename>]
shape shar[VERSIONS=<version_selection_rule>] [ARCHIVE=<filename>]
DESCRIPTION
Shape tar and shape shar create a tar or a shar archive containing all source components of the current node in the system tree. All source
components listed in the COMPONENTS macro in the Makefile and the release identification file (VERSIONFILE) are written to the archive.
Components of subsystems are not included in the archive file.
The VERSIONS macro may be set to specify a version selection rule to be active during archive file creation. Default is most_recent,
selecting the most recent version of each component. See shape_stdrul(7) or the $(SHAPELIBPATH)/stdrules for other possible settings. You
may also use self defined version selection rules as VERSIONS.
ARCHIVE is the base name of the file where the output shall be written to. Default is $(SUBSYSTEMNAME). The output file gets the filename
extension .tar (resp. .shar). When ARCHIVE=- is given, data will be written to standard output.
SEE ALSO shape_RMS(1), shape_stdrul(7)FILES
$(SUBSYSTEMNAME).tar $(SUBSYSTEMNAME).shar
7.8.119 SHAPE_TAR(1)