batch job

Dazed_75 lthielster at gmail.com
Sat Aug 6 11:52:13 MST 2011


Thanks you folks!

Dale had the easiest solution for my question (and I think I may even
remember it :).

Brian, I had a hard time figuring yours out but only because the empty
replacement text made it unclear AND that the explanation was way far down
in the tldp page you referenced.

Ed, I was not able to get detox to compile on my Ubuntu 10.04 system.  I
THINK it was because there is no lex/yacc here as noted was needed in the
README.

larry at triggerfish:~/Downloads/tmp/detox-1.2.0$ make
> gcc -o detox detox.o file.o clean_string.o table.o parse_table.o
> config_file_l.o config_file_y.o config_file_spoof.o config_file_dump.o
> parse_options_getopt.o parse_options_generic.o
> config_file_l.o: In function `yylex':
> /home/larry/Downloads/tmp/detox-1.2.0/lex.yy.c:1010: undefined reference to
> `yywrap'
> collect2: ld returned 1 exit status
> make: *** [detox] Error 1
> larry at triggerfish:~/Downloads/tmp/detox-1.2.0$
>

and there is no yacc in the repositories, just a number of replacements for
it.  The above error is from after installing bison which seemed likely to
be the clearest path.

I don't think I will pursue that further at this time although detox might
be useful sometime.  Thanks again.

On Sat, Aug 6, 2011 at 8:59 AM, Ed <plug at 0x1b.com> wrote:

> On Fri, Aug 5, 2011 at 6:16 PM, Brian Parma <freecode at cox.net> wrote:
> > On 08/05/2011 03:45 PM, Dazed_75 wrote:
> >
> > I have finished doing the work but did it manually.  For future
> reference,
> > I'd like to re-learn what I forgot from 20+ years ago about how to do
> this
> > the easy way.  Basically, I had a directory full of files that I wanted
> to
> > process all the same way and rename them in the process.  What I could
> not
> > remember was how with globbing, I could specify the output name part that
> > was wild-carded in the input should be used in the output.
> >
> > Lets say I have a bunch of files named Screenshot-PXEmenu-*.png and I
> want
> > to copy or rename them to PXEmenu-*.png.  Both mv and copy fail
> > (understandably?) using "<command> Screenshot-PXEmenu-*.png
> PXEmenu-*.png".
> > I am pretty sure there is a way to make one or both work with a syntax
> for
> > the target I do not remember.  Any clues?
> >
> > The names are real, though what I was really doing was using the convert
> > command of ImageMagick to negate all the colors in those screenshots so I
> > had a specified input and output file anyway.  NTL, the base question
> here
> > is the real one.
> > --
> > Dazed_75 a.k.a. Larry
> >
>  Hi Larry, if the files have spaces in them, I make my life easier and
> run detox[1] on them first. Otherwise the command rename should do
> what you want: rename FROMpattern TOpattern Files
>
> rename Screenshot-PXE PXE Screenshot-PXE*
>
> if the files had spaces you wanted to keep.. do a find with the
> -print0 into an xargs with the -0 option that runs the rename.
> also bash does slice up strings in variables - see # ## % %% - kind of
> a match 'n scratch - good for scripting.
> x=Screenshot
> echo ${x#Screen}
>
> Ed
> [1] http://sourceforge.net/projects/detox/
> ---------------------------------------------------
> PLUG-discuss mailing list - PLUG-discuss at lists.plug.phoenix.az.us
> To subscribe, unsubscribe, or to change your mail settings:
> http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss
>



-- 
Dazed_75 a.k.a. Larry

The spirit of resistance to government is so valuable on certain occasions,
that I wish it always to be kept alive.
  - Thomas Jefferson
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.PLUG.phoenix.az.us/pipermail/plug-discuss/attachments/20110806/b6ab17fd/attachment.html>


More information about the PLUG-discuss mailing list