From: zzapper <david@tvis.co.uk>
To: zsh-users@sunsite.dk
Subject: Re: Creating a Case statement dynamically
Date: Wed, 29 Jun 2005 11:34:05 +0100 [thread overview]
Message-ID: <ubs4c1d79rv0o13vctj5hb4ten2nbr1vrr@4ax.com> (raw)
In-Reply-To: <4880307205062815506511f134@mail.gmail.com>
On Tue, 28 Jun 2005 15:50:54 -0700, wrote:
>2005/6/28, Nikolai Weibull <mailing-lists.zsh-users@rawuncut.elitemail.org>:
>> zzapper wrote:
>>
>> > I have script which lists a series of files I might wish to edit
>> >
>> > I'd like the script to dynamically output a case
>>
>> Use an array/list and select the nth element from it,
>> nikolai
>>
>
>I suggest the "select" loop. For example:
>
>select f in **/*.tex; do
> if [[ "$REPLY" = q ]]; then
> break
> elif [[ -n "$f" ]]; then
> gvim $f
> fi
>done
>
>Note that this block will loop until you exit with ^C or q.
thx just what I was looking for!
--
zzapper
vim -c ":%s%s*%Cyrnfr)fcbafbe[Oenz(Zbbyranne%|:%s)[[()])-)Ig|norm Vg?"
http://www.rayninfo.co.uk/tips/ vim, zsh & success tips
prev parent reply other threads:[~2005-06-29 10:35 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-06-28 17:24 zzapper
2005-06-28 17:58 ` Nikolai Weibull
2005-06-28 22:50 ` John Reese
2005-06-29 10:34 ` zzapper [this message]
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=ubs4c1d79rv0o13vctj5hb4ten2nbr1vrr@4ax.com \
--to=david@tvis.co.uk \
--cc=zsh-users@sunsite.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).