Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: suffix alias problem



On Thu, 10 Nov 2011 17:36:55 +0100
Dieter Faulbaum <Dieter.Faulbaum@xxxxxxxxxxxxxxxxxxx> wrote:
> is it possible that the zsh-mime-setup can use something like this:
> 
> zstyle ':mime:.pdf(|.gz):' handler 'evince %s'
> 
> because evince can gunzip files "on the fly"?

In principle it ought to be possible to do something like that, or 

zstyle ':mime:.pdf:' handler 'evince %s'
zstyle ':mime:.pdf.gz:' handler 'evince %s'

though the shell doesn't do a search for the longest suffix match at the
moment.  I'll try to remember to look into it.  You'd need to make sure
there is some rule to handle .gz files even so, or set up the suffix
alias by hand, to ensure zsh-mime-handler runs; alias -s
gz=zsh-mime-handler would be good enough.

-- 
Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>
Web page now at http://homepage.ntlworld.com/p.w.stephenson/



Messages sorted by: Reverse Date, Date, Thread, Author