Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!bloom-beacon!hermes!dzenc From: dzenc@hermes.ai.mit.edu (Daniel Zenchelsky) Newsgroups: comp.sys.amiga Subject: Re: Move cmd (was: Find 1.2 (praise and small bug report)) Message-ID: <3317@hermes.ai.mit.edu> Date: 31 Mar 89 00:16:43 GMT References: <7624.AA7624@heimat> Reply-To: dzenc@hermes.ai.mit.edu.UUCP (Daniel Zenchelsky) Organization: The MIT AI Lab, Cambridge, MA Lines: 82 In article <7624.AA7624@heimat> sneakers@heimat.UUCP (Dan "Sneakers" Schein) writes: >In Message <26@hcr.UUCP>, edwin@hcr.UUCP (Edwin Hoogerbeets) writes: > >>Keep those little utils coming. (I'm almost finished a mv that will move >>directories across devices, preserve permissions, dates, filenotes, etc. >>I will send it in when it stops guruing. :-) > > Does it support wildcards ?!? The one thing I would like to do is: > > 1> mv news:comp.sys.amiga/#? news:comp.sys.amiga.archive > > (Yes I know its not a hard thing to write, im just busy & lazey ;-) > > Sneakers > >-- > ___ > Dan "Sneakers" Schein //// BERKS AMIGA BBS > Sneakers Computing //// 60+ Megs of software & messages > 2455 McKinley Ave. ___ //// 12/2400 Baud - 24 Hrs > West Lawn, PA 19609 \\\\ //// 215/678-7691 > \\\\//// > {pyramid|rutgers|uunet}!cbmvax!heimat!sneakers Heres my little baby that I use instead of rename (it's a fixed version of what I posted a little while ago): It works under 1.3. .key pat,TO IF EQ "" SKIP USAGE ENDIF IF EQ "" SKIP USAGE ENDIF failat 21 rename > nil: IF FAIL assign temp<$$>: IF NOT FAIL list >t:q<$$> lformat="rename *"%s%s*" *"temp<$$>:%s*"" IF NOT FAIL execute t:q<$$> ELSE echo " not found" ENDIF ENDIF ENDIF SKIP DONE LAB USAGE ECHO "" ECHO "mv - By Daniel Zenchelsky" ECHO "" ECHO " (1) mv [DIR]FILE [to] [DIR]FILE " ECHO " (2) mv FILE [to] DIR " ECHO " (3) mv PATTERN [to] DIR " ECHO "" LAB DONE failat 10 assign temp<$$>: ; single file rename, single file move, or multiple file move Have Fun -Dan +-----------------------------------------------------------+ | ______ | | || |o| Daniel Zenchelsky -- dzenc@hermes.ai.mit.edu | | ||___| | | | | _ | "Yes, but every time I try to see things your | | \_[]_|_| way, I get a headache." | | | +-----------------------------------------------------------+