saini@silver.bacs.indiana.edu (07/21/88)
I wanted to know whether there was a way to use (or simulate) wild-card in DOSREAD and DOSWRITE. It becomes a pain to copy all the files individually to minix from DOS. Iqbal
steve@basser.oz (Stephen Russell) (07/21/88)
In article <26500003@silver> saini@silver.bacs.indiana.edu writes: > >I wanted to know whether there was a way to use (or simulate) >wild-card in DOSREAD and DOSWRITE. It becomes a pain to copy all the >files individually to minix from DOS. > How about using dosdir to get a list of files, grep for the ones you want, then use command substitution with the shell; ie dosread `dosdir ... | grep funky_stuff` Of course, if the minix sh doesn't support command substitution, save the output of the grep, use gres to convert it to a series of "dosread" commands, then run that through the shell. Lot's of fun - you could even make a shell script of it for future use.
pointer@hpccc.HP.COM (David Pointer) (07/22/88)
I have found that making a shell script helps. But, yeah, wildcards would be nice... David Pointer pointer@hpda
paula@bcsaic.UUCP (Paul Allen) (07/23/88)
In article <26500003@silver> saini@silver.bacs.indiana.edu writes: > >I wanted to know whether there was a way to use (or simulate) >wild-card in DOSREAD and DOSWRITE. It becomes a pain to copy all the >files individually to minix from DOS. > >Iqbal How 'bout something like: for n in `ls *` do doswrite 1 $n <$n done This copies all the files in the current directory to DOS files on the B: drive. To copy from a DOS floppy into Minix, you need to somehow generate a list of the filenames to copy. Then the actual copy can be done with: for n in `cat copylist` do dosread 1 $n >$n done Anybody else have a better method? Paul -- ------------------------------------------------------------------------ Paul L. Allen | paula@boeing.com Boeing Advanced Technology Center | ...!uw-beaver!ssc-vax!bcsaic!paula
woodman@suvax1.UUCP (David Woodman) (07/23/88)
This may be kind of dumb, but I use a shell script. Recipe follows - dosdir 0 > out1 (remove leading and trailing stuff from out1, leaving only filenames) ( I haven't written a script to do this but I should. ) tr "[A-Z]" "[a-z]" < out1 > out2 rm out1 for i in `cat out2` do echo $i dosread -a 0 $i > $i done - And that does it. If your industrious enough, you may want to write a more robust (flexible) script and post it. So far, I just keep re-making the wheel when I need it. ------------------------------------------------------------------------------ David Woodman UUCP: ...!uw-entropy!dataio!suvax1!woodman Seattle University USNail: P.O. Box 23202, Seattle WA 98102 Phone: (206) 223-9470 ------------------------------------------------------------------------------
dws@cseg.uucp (David W. Summers) (07/25/88)
In article <26500003@silver>, saini@silver.bacs.indiana.edu writes: > > I wanted to know whether there was a way to use (or simulate) > wild-card in DOSREAD and DOSWRITE. It becomes a pain to copy all the > files individually to minix from DOS. > > Iqbal One way that I did it was to just write a one line shell script which will go through each of the desired files and read/write it to the DOS disk. I forget the syntax of the command right now, but it only took me 5 minutes or so to look it up and create a one-liner. - David Summers dws@cseg.uucp ..!romed!cseg!dws
roskos@csed-1.IDA.ORG (Eric Roskos) (07/28/88)
>I wanted to know whether there was a way to use (or simulate) >wild-card in DOSREAD and DOSWRITE. It becomes a pain to copy all the >files individually to minix from DOS. I do this by tarring everything onto a multivolume tar floppy. I posted sources & executables for this tar* in comp.binaries.ibm.pc about a month ago. You can transfer arbitrarily large directory trees between Dos and Minix this way (it converts between CRLF and LF too). Only works with 360K floppy at present though since I don't have a 1.2M floppy (one is on order, though) & so there was a bug in the 1.2M archive code for DOS. See the man page from the comp.binaries.ibm.pc posting for instructions. AST's tar should work on the Minix side, though I haven't tried it with that tar -- he used that one instead because it is MUCH more compact than PD-tar (the sources). *A port of John Gilmore's PD-Tar to DOS and Minix, with multivolume floppy support and CR/LF & filename conversion added. The only real changes are for DOS (unless you add some nonstandard changes to Minix), so the current Minix tar should be compatible with that one on the Minix side. -- Eric Roskos, IDA (csed-1!roskos or Roskos@DOCKMASTER.ARPA) "See how God with his lightning always smites the bigger animals, and will not suffer them to wax insolent ..." --Artabanis, adv. to Xerxes