home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Atari FTP
/
ATARI_FTP_0693.zip
/
ATARI_FTP_0693
/
Mint
/
mntlib32.zoo
/
crlf
/
crlf.doc
< prev
next >
Wrap
Text File
|
1993-02-11
|
1KB
|
34 lines
crlf.c by entropy@terminator.rs.itd.umich.edu
PUBLIC DOMAIN -- NO RIGHTS RESERVED
usage: crlf -s file [file2 [...]] (to strip carriage returns)
crlf -a file [file2 [...]] (to add carriage returns)
crlf converts text files between TOS (MS-DOS) and UNIX style line
terminators.
With the -s option, it strips all carriage returns from the specified files.
With the -a option, it adds carriage returns before each line feed in a
file. Be careful that you do not run this twice on the same file (or at all
on a file that already has carriage returns) as you will end up with really
strange line terminators that way (recover by stripping and re-adding
returns.
If any errors/warnings occur while trying to convert a file, an error status
will be returned to the OS when the program exits. If you are running from
a Makefile and know there will be errors (e.g. "crlf -s *" in a directory
that contains subdirectories) you should ignore the return status (e.g.
"-crlf -s *" in a Makefile).
The program attempts to preserve the timestamp of the original file. If it
is unable to do so it will continue to convert the file but will return an
error status to the OS.
crlf does NOT recursively convert subdirectories as of yet.
The program is 16/32 bit clean.
Enjoy,
entropy