."\ Master source for addcr : /usr/src/local/man/src/addcr.rof .TH ADDCR P "Manual V1.2 for Program V1.7" "Julian Stacey" "Julian Stacey, Vector Systems Ltd" .\" A4 the cludgy way. .pl 29.6c .UC 4 .SH NAME addcr \- Ensure each line terminates with a \ \. .SH SYNTAX .B addcr [-d] [-r] [-v] [-V] [files] .SH DESCRIPTION .in +2 .ti -2 - Normally prepends \\r to \\n (after first removing all \\r to save multiple \\r occuring on files processed several times). Can also work in reverse, to strip \\r\\n back to \\n sequences. Useful when moving files to and fro between Unix and Msdos. .ti -2 - Works on multiple files, write result back to same file[s]. .ti -2 - Works as a pipe if no arguments. .ti -2 - To save IO on Unix, .I addcr moves written data file to source file for regular files, but understands that hard and symbolic links, special files, directories! and sockets should not be moved, but should be rewritten. .in -2 .SH OPTIONS Parameters must precede file names. Parameters available include :- .TP .B \-d .br Preserve original date of file. .TP .B \-r .br Reverse the process, strip \\r\\n back to \\n sequences. .TP .B \-v .br Verbose mode, announce each file as processed. .TP .B \-V .br Print sccs version number of source of this program. .SH LONG LINES If any line in a file is too long, .\" what about last line ? that entire file is left unchanged. One typical cause for a line too long is EG using the -v flag to .I testblock (which emits a status line with very many \\r but just one \\n). .sp No attempt is made to map or screen out other characters (so hopfully you can safely add CR's to PAL/PLA/GAL (Programmable logic array) source files if you need to, though note if the last line has no \\n, after .I addcr has run, it will have both a \\r followed by a \\n). .SH EXIT CODE 0 if no errors, else number of files that failed. .SH BUGS Says line is too long if last line does not end with \\n. Lines with several intermittent \\r embedded in the middle of a long \\r\\n terminated line will lose their intermediate \\r's, this may be annoying if they represented `soft carriage returns' as used in some Msdos word processors. .SH HOST OP SYSTEM This utility runs on both Msdos 3.2 & Unix. .SH COPYRIGHT Program Copyright Julian H. Stacey, Munich, 28th June 1989. .br Document Copyright Julian H. Stacey, Munich, 2nd March 1990. .so author.jhs .SH FILES Temporary files with names of type adXXXXXX are created in the same directory. ( A temporary file is always used at present, malloc could later be used for smallish files.) .\ End of file