Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: mailcap configuration in zsh can't open .bk files
- X-seq: zsh-users 17963
- From: vinurs <haiyuan.vinurs@xxxxxxxxx>
- To: zsh-users@xxxxxxx
- Subject: Re: mailcap configuration in zsh can't open .bk files
- Date: Mon, 2 Sep 2013 09:28:26 +0800
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=GDOntkYkppb0Zg9ESNMWM8uV6Wpppxezejgu5uiH1Qk=; b=JztSTu/KNo02UgvtqZGLNVMz9h79Hzqj2OmL0CnKoR+7xuhWTIFsFuTSJS0xYo1HRj Wkm0ZFKZwf825GS63abU0Hpg8dnQKV0W0xC/qD72upZ96Rz8aZqe+D6trEnRKFncG44t zotaKmbegMcN+auvEx7SxDpq19G7+om3F5mJV/uNj0OanqYQDyuJSjeH2cjt3/mDSQIr xTv4DmYrxCAVMP5GQBzka0w5iEAKgUStqM+0bEj9tRZPwoxuclhMTh29zHvDTvs+hWdV BHEH/NawD/+UZYXI2oc+F1STrE9k9xvHjcg2M3Qv708GDOtVydIqsyFIf8uqc4jFfH3A jbWw==
- In-reply-to: <201309011711.r81HBEEF002418@pws-pc.ntlworld.com>
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <schaefer@brasslantern.com> <130830101018.ZM26161@torch.brasslantern.com> <201309011711.r81HBEEF002418@pws-pc.ntlworld.com>
It's not intelligent deciding filetype by suffix only, I'd like to write
functions to open flles using 'file --mime-type'
Thanks all
2013/9/2 Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>
> Bart Schaefer wrote:
> > On Aug 30, 9:29am, Peter Stephenson wrote:
> > }
> > } Hmm... the zsh-mime-setup script is smart enough to get this right if
> > } you specify pdf.bk in ~/.mime.types, e.g.
> > }
> > } application/pdf pdf pdf.bk
> > }
> > } but unfortunately the main shell isn't: given the suffix alias pdf.bk,
> > } it only looks for the .bk suffix, so the MIME handler isn't started.
> >
> > The documentation would imply that it is therefore sufficient to put the
> > pdf.pk rule in ~/.mime.types, run zsh-mime-setup, and then add
> >
> > alias -s bk=zsh-mime-handler
>
> That should work, too, since zsh-mime-handler doesn't care how it gets
> started, only the file name passed to it; what won't work is leaving it
> to zsh-mime-setup which will only add the alias for pdf.bk.
>
> I guess alternatively we could make it add a suffix alias for bk if
> there isn't one.
>
> pws
>
Messages sorted by:
Reverse Date,
Date,
Thread,
Author