zsh-users
 help / color / mirror / code / Atom feed
From: Clint Adams <schizo@debian.org>
To: Bart Schaefer <schaefer@candle.brasslantern.com>
Cc: zsh-users@sunsite.auc.dk
Subject: Re: more fun with parameter expansion
Date: Fri, 16 Jun 2000 21:17:34 -0400	[thread overview]
Message-ID: <20000616211734.A10088@scowler.net> (raw)
In-Reply-To: <000616140019.ZM4608@candle.brasslantern.com>; from schaefer@candle.brasslantern.com on Fri, Jun 16, 2000 at 02:00:19PM -0700

> Oh, and your solution missed file names that began with a dot, unless you
> meant to say that both MARK_DIRS and GLOB_DOTS were needed ...

No, I didn't.  I hadn't considered dotfiles, actually.

> The correct solution is
> 
> for f in **/*(DNOn^M); do
>   mv -v $i ${${(M)i%/*}:+${i%/*}}${${${(M)i%/*}:-$i}:l:gs/ /_/}
> done

Of course, you meant to change all the i's to f's or the f to an i.

Thanks for the shorter version.


  reply	other threads:[~2000-06-17  1:21 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-06-16 18:53 Clint Adams
2000-06-16 19:54 ` Clint Adams
2000-06-16 21:00 ` Bart Schaefer
2000-06-16 21:44   ` Bart Schaefer
2000-06-17  1:17     ` Clint Adams [this message]
2000-06-18 22:02 ` Peter Stephenson
2000-06-19  9:08   ` Peter Stephenson
2000-06-19 15:21     ` Clint Adams

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20000616211734.A10088@scowler.net \
    --to=schizo@debian.org \
    --cc=schaefer@candle.brasslantern.com \
    --cc=zsh-users@sunsite.auc.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).