05-26-2012
Probably your file is not in proper Unix format in the sense that the last line is missing a linefeed as the last character and then read will not process it.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi all,
I am a newbie in writng unix..I am using ksh shell..Does anyone know how to copy a list o files from directory A to directory B with differnt names? i.e
in Dir A, I have
RPT101.555.TXT
RPT102.666.TXT
and I want to copy those files to dir B with new naming convention..
in Dir B,... (7 Replies)
Discussion started by: kinmak
7 Replies
2. UNIX for Dummies Questions & Answers
:confused:
I have more than 8000 files in a dir, I need to copy to other dir which containing the "sample"
I tried
grep -il "1189609240791-1268115603299237276@216.109.111.119 ' | cp /tmp/inv
Nothing is happening for long time for 100 file dir too,
Any one can help me? (11 Replies)
Discussion started by: redlotus72
11 Replies
3. Shell Programming and Scripting
I will be very grateful if someone can help me with bash shell script that does the following:
I have a list of filenames:
A01_155716
A05_155780
A07_155812
A09_155844
A11_155876
that are kept in different sub directories within my current directory. I want to find these files and copy... (3 Replies)
Discussion started by: manishabh
3 Replies
4. Shell Programming and Scripting
dear all.
how can i copy a list of files with different names into others directory have the same name
like i have 3 files
10_10
10_10_11
10_10_11_12
and i have 3 directories
10_10
10_10_11
10_10_11_12
how can i make a loop to cp this files into the directory have the same name like... (0 Replies)
Discussion started by: t17
0 Replies
5. UNIX for Dummies Questions & Answers
dear all.
how can i copy a list of files with different names into others directory have the same name
like i have 3 files
10_10
10_10_11
10_10_11_12
and i have 3 directories
10_10
10_10_11
10_10_11_12
how can i make a loop to cp this files into the directory have the same name like... (31 Replies)
Discussion started by: t17
31 Replies
6. Shell Programming and Scripting
Hi,
I need to copy all files from this statement to another folder:
ls –l ./apps | grep –E “^l|^v”
How can i do that?
best regards! (8 Replies)
Discussion started by: xus
8 Replies
7. Shell Programming and Scripting
Hi.
I have a list with file names like
testfile1.wav
testfile2.wav
testfile3.wav
and a folder that contains a large number of wav files (not only the ones on the list).
I would like to copy the files whose names are on the list from the wav file directory to a new directory.
I... (5 Replies)
Discussion started by: Bloomy
5 Replies
8. Shell Programming and Scripting
Hi
I have 3 directories
indexes_with_ts
indexes_without_ts
process_indexes
in each directories it contains *.sql
how do I accomplish this:
for all the files found in indexes_without_ts, copy the corresponding file in indexes_with_ts to process_indexes.
i.e.
for... (2 Replies)
Discussion started by: jediwannabe
2 Replies
9. Shell Programming and Scripting
for XmlFileName in ${xmlFileNames}
do
XmlFileName=$(echo $XmlFileName | sed 's|./||') # Remove leading ./ path that find command prefixes to filenames
cp $XmlFileName $NEW_DIR/
done (1 Reply)
Discussion started by: emc^24sho
1 Replies
10. UNIX for Dummies Questions & Answers
Requirement:
When I do ls -ltr /home/data/orders I get a huge list of files, I need to copy that last 50 to another directory say /home/work/ later, I will do my ETL process and then again I need to copy from 51 to 100 and so on.
What is the command to copy files specifying 1 to 50... (5 Replies)
Discussion started by: eskay
5 Replies
uuencode(5) File Formats Manual uuencode(5)
NAME
uuencode file format
DESCRIPTION
The command generates files in a format that allows them to be successfully transferred by systems which strip the high bit from an 8-bit
byte. decodes uuencoded files.
The uuencode file format consists of three sections: header, body, and trailer. The header is a line is of the form:
begin 644 "filename.ext"
where "644" is a -format permissions byte for the file and "filename.ext" is the name of the encoded file.
The body section is the encoded representation of the source file. Three bytes of input file data are encoded into four bytes of output
data.
The 24 input bits are divided up into four pieces of six bits each. The integer value 32 (the ASCII value for the space character) is added
to each of these pieces to move them outside of the range of control characters. To avoid using the space character in the encoding, pieces
with value zero are encoded using backquote (ASCII value 96) instead of zero. The resulting character is one of the this set (ASCII values
96,33-95):
A line itself contains three segments: a length character (encoded using the "add a space" algorithm described above), the body of the
line, typically (although not required to be) 60 output characters long, representing 45 input bytes, and (of course) a linefeed. The
length character specifies the number of valid input bytes on the line (so, for a line which is 60 encoded bytes, the length value would be
45). Decoding programs should decode no further than the specified length on a single line.
The trailer, which must exist, consists of a single backquote ("`", ASCII 96) character on a line by itself, directly followed by on a line
by itself.
is the canonical filename extension for uuencoded files.
BUGS
uudecode does not read all permutations of the file format described in this man page.
Ancient versions of uuencode used a space character (ASCII 32) in the encoding to represent zero. Many (arguably broken) mailers and trans-
port agents stripped, rewrapped, or otherwise mangled this format, so the space was later changed to the backquote, ASCII 96. Decoders may
attempt to read the older format if they wish, though it's unlikely to be encountered in practice at this point in time.
The uuencode encoding method is highly ASCII-centric. In particular, the character set used doesn't work well on EBCDIC-based systems.
(EBCDIC, generally used by IBM mainframes, is an old alternative character encoding; most computers use ASCII instead).
Many variants of uuencode on various platforms generate different forms of line checksums, using to represent the checksum one or more
encoded characters after the last counted character in a line. Because these formats are different and impossible to distinguish (with
certainty), such characters should be ignored by decoding implementations.
The uuencode encoding format has no provisions for segmented files. Writers of segmenting utilities should be careful to avoid using char-
acter sequences that may naturally occur in the encoding (such as sequences of dashes ("---")) to divide sections.
SEE ALSO
The MIME Base64 encoding (documented in RFC 2045) is a consistent, cross-platform-savvy message encoding which should be used in place of
UUEncode wherever possible.
The Unix-Hater's Handbook (IDG, 1994) identifies the folly of the older zero-encoded-as-space versions of uuencode.
Apple Computer, Inc. May, 2001 uuencode(5)