in reply to Perl on windows, one-liners with wildcards/glob

perl -pi.bak -e "INIT{@ARGV=<@ARGV>}s/vanilla/strawberry/gi" *.txt *.d +oc

Replies are listed 'Best First'.
Re^2: Perl on windows, one-liners with wildcards/glob
by halley (Prior) on Oct 23, 2011 at 13:53 UTC
    Finally a golf answer, and I learned something from it. I knew of <*.txt> but had no idea that it allowed for multiple globs at once, such as <*.txt *.doc>.

    --
    [ e d @ h a l l e y . c c ]

Re^2: Perl on windows, one-liners with wildcards/glob
by Jim (Curate) on Oct 27, 2011 at 06:16 UTC

    Is there a reason to use INIT instead of BEGIN except to play golf?