d

doscp(1)

doscp(1)

NAME

doscp - copy to or from DOS ®les

SYNOPSIS

doscp [-fvu]®le1 ®le2

doscp [-fvu]®le1 [ ®le2 ... ] directory

DESCRIPTION

doscp is the DOS counterpart of cp (see cp(1)). doscp copies a DOS ®le to a DOS or HP-UX®le, an HP- UX ®le to an HP-UXor DOS ®le, or HP-UXor DOS ®les to an HP-UXor DOS directory. The last name in the argument list is the destination ®le or directory.

A DOS ®le name is recognized by the presence of an embedded colon (:) delimiter; see dosif(4) for DOS ®le naming conventions.

Metacharacters *, ?, and [ ... ] can be used when specifying both HP-UXand DOS ®le names. These must be quoted when specifying a DOS ®le name, because ®le name expansion must be performed by the DOS util- ities, not by the shell. DOS utilities expand ®le names as described in regexp(5) under PATTERN MATCH-

ING NOTATION.

The ®le name - (dash) is interpreted to mean standard input or standard output depending upon its position in the argument list.

Options

doscp recognizes the following options:

-fUnconditionally write over an existing ®le. In the absence of this option, doscp asks permission to overwrite an existing HP-UX®le.

-vVerbose mode. doscp prints the source name.

-uDisable argument case conversion. In the absence of this option, all DOS ®le names are converted to upper case.

RETURN VALUE

doscp returns 0 if all ®les are copied successfully. Otherwise, it prints a message to standard error and returns with a non-zero value.

EXAMPLES

Copy the ®les in the HP-UXdirectory abc to the DOS volume stored as HP-UX®le hard_disk:

doscp abc/* hard_disk:

Copy DOS ®le /backup/log through the HP-UXspecial ®le /dev/rfd9127 to HP-UX®le logcopy located in the current directory:

doscp /dev/rfd9127:/backup/log logcopy

Copy DOS ®le zulu on the volume stored as HP-UX®le bb to standard output: doscp bb:zulu -

Copy all ®les in directory /dameron with extension txt in the DOS volume /dev/rdsk/c1t2d0 to the HP-UXdirectory abacus located in the current directory:

doscp '/dev/rdsk/c1t2d0:/dameron/*.txt' abacus

WARNINGS

doscp works more reliably if you use a raw device special ®le (/dev/rdsk/) than a block device special ®le.

To use SCSI ¯oppy disk devices, the sflop device driver must be con®gured into the kernel. (You can use the ioscan command to verify the con®guration.)

SEE ALSO

cp(1), dos2ux(1), doschmod(1), dosdf(1), dosls(1), dosmkdir(1), dosrm(1), ioscan(1M) dosif(4).

Section 1188

− 1 −

HP-UX Release 11i: December 2000