Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: executing commands in directories containing specific files
All, thanks a lot. That worked!
On Wed, Feb 12, 2014 at 6:33 AM, Michel <michel.barret@xxxxxxxxx> wrote:
> >
> > I like using the (e) flag, but it's sometimes tricky to get right on the
> > first try because you have to be careful to match up the parens in the
> > reply=(...) assignment, the quotes around the expression, the outer set
> > of delimiters (I used [...] below) and the parens around the whole thing:
> >
> > rm **/*.tex(.e['reply=(${REPLY:r}.aux)'])
> >
> > But you can also use colon-modifiers as glob qualifiers, so if the .tex
> > never appears anywhere but at the end:
> >
> > rm **/*.tex(.:s/.tex/.aux)
> >
>
> thanks for this solutions interesting !
>
>
> >
> > If you've already got the filenames, say, in an array:
> >
> > texi=( $(find $HOME -type f -name '*.tex') )
> >
>
> Why use find instead the glob way :
> texi=( **/*.tex(.) )
>
> When the result is use as a stream find is a beter way but to create an
> array ?
> _____________________
> Michel BARRET
>
Messages sorted by:
Reverse Date,
Date,
Thread,
Author