blob: 41d39f7aa60cc9ee928d785c20eb5787b8c28878 [file] [log] [blame]
Alistair Delvabeaee832021-02-24 11:27:23 -08001'\" t
Yi Kong39bbd962022-01-09 19:41:38 +08002.TH mcopy 1 "08Jan22" mtools-4.0.37
Alistair Delvabeaee832021-02-24 11:27:23 -08003.SH Name
4mcopy - copy MSDOS files to/from Unix
5'\" t
6.de TQ
7.br
8.ns
9.TP \\$1
10..
11
12.tr \(is'
13.tr \(if`
14.tr \(pd"
15
16.SH Note\ of\ warning
17This manpage has been automatically generated from mtools's texinfo
18documentation, and may not be entirely accurate or complete. See the
19end of this man page for details.
20.PP
21.SH Description
22.PP
23The \fR\&\f(CWmcopy\fR command is used to copy MS-DOS files to and from
24Unix. It uses the following syntax:
25.PP
26
27.nf
28.ft 3
29.in +0.3i
30\&\fR\&\f(CWmcopy [\fR\&\f(CW-bspanvmQT] [\fR\&\f(CW-D \fIclash_option\fR\&\f(CW] \fIsourcefile\fR\&\f(CW \fItargetfile\fR\&\f(CW
31\&\fR\&\f(CWmcopy [\fR\&\f(CW-bspanvmQT] [\fR\&\f(CW-D \fIclash_option\fR\&\f(CW] \fIsourcefile\fR\&\f(CW [ \fIsourcefiles\fR\&\f(CW\&... ] \fItargetdirectory\fR\&\f(CW
32\&\fR\&\f(CWmcopy [\fR\&\f(CW-tnvm] \fIMSDOSsourcefile\fR\&\f(CW
33.fi
34.in -0.3i
35.ft R
36.PP
37
38\&\fR
39.PP
40\&\fR\&\f(CWMcopy\fR copies the specified file to the named file, or copies
41multiple files to the named directory. The source and target can be
42either MS-DOS or Unix files.
43.PP
44The use of a drive letter designation on the MS-DOS files, 'a:' for
45example, determines the direction of the transfer. A missing drive
46designation implies a Unix file whose path starts in the current
47directory. If a source drive letter is specified with no attached file
48name (e.g. \fR\&\f(CWmcopy a: .\fR), all files are copied from that drive.
49.PP
50If only a single, MS-DOS source parameter is provided (e.g. "mcopy
51a:foo.exe"), an implied destination of the current directory
52(`\fR\&\f(CW.\fR') is assumed.
53.PP
54A filename of `\fR\&\f(CW-\fR' means standard input or standard output, depending
55on its position on the command line.
56.PP
57\&\fR\&\f(CWMcopy\fR accepts the following command line options:
58.TP
59\&\fR\&\f(CWt\fR\
60Text file transfer. Mcopy translates incoming carriage return/line
61feeds to line feeds when copying from MS-DOS to Unix, and vice-versa when
62copying from Unix to MS-DOS.
63.TP
64\&\fR\&\f(CWb\fR\
65Batch mode. Optimized for huge recursive copies, but less secure if a
66crash happens during the copy.
67.TP
68\&\fR\&\f(CWs\fR\
69Recursive copy. Also copies directories and their contents
70.TP
71\&\fR\&\f(CWp\fR\
72Preserves the attributes of the copied files
73.TP
74\&\fR\&\f(CWQ\fR\
75When mcopying multiple files, quits as soon as one copy fails (for
76example due to lacking storage space on the target disk)
77.TP
78\&\fR\&\f(CWa\fR\
79Text (ASCII) file transfer. \fR\&\f(CWASCII\fR translates incoming carriage
80return/line feeds to line feeds.
81.TP
82\&\fR\&\f(CWT\fR\
83Text (ASCII) file transfer with character set conversion. Differs from
84\&\fR\&\f(CW-a\fR in the \fR\&\f(CWASCII\fR also translates incoming PC-8 characters
85to ISO-8859-1 equivalents as far as possible. When reading DOS files,
86untranslatable characters are replaced by '\fR\&\f(CW#\fR'; when writing DOS files,
87untranslatable characters are replaced by '\fR\&\f(CW.\fR'.
88.TP
89\&\fR\&\f(CWn\fR\
90No confirmation when overwriting Unix files. \fR\&\f(CWASCII\fR doesn't
91warn the user when overwriting an existing Unix file. If the target
92file already exists, and the \fR\&\f(CW-n\fR option is not in effect,
93\&\fR\&\f(CWmcopy\fR asks whether to overwrite the file or to rename the new
94file (see \(ifname clashes\(is) for details). In order to switch off
95confirmation for DOS files, use \fR\&\f(CW-o\fR.
96.TP
97\&\fR\&\f(CWm\fR\
98Preserve the file modification time.
99.TP
100\&\fR\&\f(CWv\fR\
101Verbose. Displays the name of each file as it is copied.
102.PP
103.SH Bugs
104Unlike MS-DOS, the '+' operator (append) from MS-DOS is not
105supported. However, you may use \fR\&\f(CWmtype\fR to produce the same effect:
106
107.nf
108.ft 3
109.in +0.3i
110mtype a:file1 a:file2 a:file3 >unixfile
111mtype a:file1 a:file2 a:file3 | mcopy - a:msdosfile
112.fi
113.in -0.3i
114.ft R
115.PP
116
117\&\fR
118.PP
119.SH See\ Also
120Mtools' texinfo doc
121.SH Viewing\ the\ texi\ doc
122This manpage has been automatically generated from mtools's texinfo
123documentation. However, this process is only approximative, and some
124items, such as crossreferences, footnotes and indices are lost in this
125translation process. Indeed, these items have no appropriate
126representation in the manpage format. Moreover, not all information has
127been translated into the manpage version. Thus I strongly advise you to
128use the original texinfo doc. See the end of this manpage for
129instructions how to view the texinfo doc.
130.TP
131* \ \
132To generate a printable copy from the texinfo doc, run the following
133commands:
134
135.nf
136.ft 3
137.in +0.3i
138 ./configure; make dvi; dvips mtools.dvi
139.fi
140.in -0.3i
141.ft R
142.PP
143
144\&\fR
145.TP
146* \ \
147To generate a html copy, run:
148
149.nf
150.ft 3
151.in +0.3i
152 ./configure; make html
153.fi
154.in -0.3i
155.ft R
156.PP
157
158\&\fRA premade html can be found at
159\&\fR\&\f(CW\(ifhttp://www.gnu.org/software/mtools/manual/mtools.html\(is\fR
160.TP
161* \ \
162To generate an info copy (browsable using emacs' info mode), run:
163
164.nf
165.ft 3
166.in +0.3i
167 ./configure; make info
168.fi
169.in -0.3i
170.ft R
171.PP
172
173\&\fR
174.PP
175The texinfo doc looks most pretty when printed or as html. Indeed, in
176the info version certain examples are difficult to read due to the
177quoting conventions used in info.
178.PP