Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Alias and zstyle contexts
- X-seq: zsh-users 19516
- From: Mikael Magnusson <mikachu@xxxxxxxxx>
- To: Mikael Magnusson <mikachu@xxxxxxxxx>, Zsh Users <zsh-users@xxxxxxx>
- Subject: Re: Alias and zstyle contexts
- Date: Wed, 10 Dec 2014 02:41:29 +0100
- 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=RS/w1Cco1DcqsEXz+fD/5gPuAo/ha3mAHYBlnQWkujs=; b=c8hBWgdIeGm6keqMxOXDg8tKEGui9mZFQTaqimwTcQGLMiVKFKu8WrW7i4EAPIQCcU IcvFgaaZFOVuox8HoQDsiRlu2O9GWxa+QTvjLlX8gUsecVo82FKyNRlgBpjOWUarZtoC a+yUbtKK3ymkm8cr8k/twGOT2jijoqCUhPnDpnD7vtQREo5sZGVjvbDcnwkHd55SsGvT SCPcfKN8+XwOyhlre/jcmmVwiMAgYPri9ywfb5V6Lj4TxOdWVw5nCkhv0zsf8ogMAhvw NnS7s6jxM9kdhqHkidn18k6wKigzxib+EH2dj28aEIa6LlieOkwYFRvHHKoBKuaCVPXn SwlQ==
- In-reply-to: <20141209161119.GA2492@rikku>
- 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: <20141208230255.GA6029@rikku> <CAHYJk3Q81kkEP7A+itV7E3JytKx7gVBsS80L8RYzTeeKbCrS6g@mail.gmail.com> <20141209161119.GA2492@rikku>
On Tue, Dec 9, 2014 at 5:11 PM, Silas Silva <silasdb@xxxxxxxxx> wrote:
> On Tue, Dec 09, 2014 at 12:24:34AM +0100, Mikael Magnusson wrote:
> (...)
>> > mutt's -f option looks for mailboxes using the mail-directory style. I
>> > have a "muttw" alias that I'd like to load mailboxes from another
>> > directory, but the context is the same.
> (...)
>>
>> Just making a function and saying compdef muttw=mutt should be enough.
>
> Hi!
>
> It works fine, thank you! But, unfortunately zsh's _mutt file checks
> if $curcontext is mutt or some other alternatives. Since I now have
> muttw context, it doesn't work well. Is it possible to trick _mutt
> without having to change its code?
>
> Thank you very much.
I don't have mutt so I can't try this, and if it doesn't work, maybe
someone else has a suggestion.
compdef -e 'curcontext=:complete:mutt:w:; _mutt' muttw
and then set the mail-directory style for that tag instead. Maybe?
There may be some much more elegant way to do this (if it at all
works).
--
Mikael Magnusson
Messages sorted by:
Reverse Date,
Date,
Thread,
Author