Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options

Re: looking for a quickie

by BrowserUk (Pope)
on Mar 18, 2003 at 19:08 UTC ( #244127=note: print w/ replies, xml ) Need Help??

in reply to How do I execute a shell command against each file in a directory and it's subdirectories? (was: looking for a quickie)

No perl, cygwin or 4NT required:)

for /F %f in ('dir /s /b') do doit -switches %f

Examine what is said, not who speaks.
1) When a distinguished but elderly scientist states that something is possible, he is almost certainly right. When he states that something is impossible, he is very probably wrong.
2) The only way of discovering the limits of the possible is to venture a little way past them into the impossible
3) Any sufficiently advanced technology is indistinguishable from magic.
Arthur C. Clarke.

Comment on Re: looking for a quickie
Download Code
Replies are listed 'Best First'.
Re: Re: looking for a quickie
by jsprat (Curate) on Mar 18, 2003 at 19:35 UTC
    ++BUK for getting me to look at the cmd.exe docs!

    Here's another snippet -

    for /R %f in (*) do doit -switches %f

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://244127]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (3)
As of 2015-10-04 05:43 GMT
Find Nodes?
    Voting Booth?

    Does Humor Belong in Programming?

    Results (99 votes), past polls