Copies DOS files to AIX files.
dosread [ -a ] [ -v ] [ -D Device ] File1 [ File2 ]
The dosread command copies the DOS file specified by the File1 variable to standard output or to the AIX file specified by the File2 variable. If no pathname is specified for the File2 variable, the DOS file is copied to the root directory.
Unless otherwise specified, the dosread command copies the number of bytes specified in the directory entry for the file specified by the File1 variable. This means, in particular, that you cannot copy directories because, by convention, directories have a record size of 0.
You can use DOS file-naming conventions with one exception: the \ (backslash). Because the \ character can have special meaning in DOS, use a / (slash) character as the delimiter to specify subdirectory names in a DOS path name. The dosdir command converts lowercase characters in the file or directory name to uppercase before it checks the disk. Because all file names are assumed to be full (not relative) path names, you need not add the initial / (slash).
Notes:
- The dosread command does not interpret the * and ? (asterisk and question mark) wildcard characters as having special meaning. If you do not specify a file-name extension, the file name is matched as if you had specified a blank extension.
- You cannot customize the name of this command. The command must be named dosread.
- The dosread command reads files from the default drive containing the DOS diskette. The dosread command then copies the files to the current AIX directory as AIX files. If the DOS diskette contains subdirectories, the dosread command does not create corresponding new subdirectories in AIX. You must create the subdirectory for AIX and specify each DOS file you want to copy into the new AIX subdirectory.
dosread -a chap1.doc chap1This command sequence copies the DOS text file \CHAP1.DOC on default device /dev/fd0 to the AIX file chap1 in the current directory.
dosread -D/dev/fd1 /survey/test.dta /home/fran/testdataThis command sequence copies the DOS data file \SURVEY\TEST.DTA on /dev/fd1 to the AIX file /home/fran/testdata.
dosdir | awk '!/There are/ {print $1}'|xargs -t -i dosread {} {}This command sequence takes files from the default drive containing the DOS disk and copies them to the current directory as AIX files.
/usr/bin/dosread | Contains the dosread command. |
/dev/fd0 | Contains the device name for a diskette drive. |
The awk command, dosdel command, dosdir command, dosformat command, doswrite command, xargs command.
File Systems and Directories Overview in AIX Version 4.3 System User's Guide: Operating System and Devices.
Files Overview in AIX Version 4.3 System User's Guide: Operating System and Devices describes files, file types, and how to name files.