zsh-users
 help / color / mirror / code / Atom feed
* Creating a Case statement dynamically
@ 2005-06-28 17:24 zzapper
  2005-06-28 17:58 ` Nikolai Weibull
  0 siblings, 1 reply; 4+ messages in thread
From: zzapper @ 2005-06-28 17:24 UTC (permalink / raw)
  To: zsh-users

Hi  Z-men


I have script which lists a series of files I might wish to edit

manuals/client-man-admin.tex
manuals/client-man-catalogbasket.tex
manuals/client-man-userguide.tex
quotes/client-admin.tex
quotes/client.tex

I'd like the script to dynamically output a case such


vared -p " Type number to edit or q" -c action
case $action in
 1) gvim manuals/clientman-admin.tex ;;
 2) gvim manuals/clientman-catalogbasket.tex ;;
 etc
 q) exit 0;;
 *) ;; # everything else including return: do nothing
esac

but how to do?

Alternative solutions welcome


-- 
zzapper
vim -c ":%s%s*%Cyrnfr)fcbafbe[Oenz(Zbbyranne%|:%s)[[()])-)Ig|norm Vg?"
http://www.rayninfo.co.uk/tips/ vim, zsh & success tips


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2005-06-29 10:35 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-06-28 17:24 Creating a Case statement dynamically zzapper
2005-06-28 17:58 ` Nikolai Weibull
2005-06-28 22:50   ` John Reese
2005-06-29 10:34     ` zzapper

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).