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

Re: PATCH: _ps1234, _date_formats: Complete strftime formats for %D{}



On Thu, Jul 9, 2015 at 2:17 PM, Oliver Kiddle <okiddle@xxxxxxxxxxx> wrote:
> Mikael Magnusson wrote:
>>
>> I've also just noticed that completion after %D\{%\# and \^ doesn't
>> work, but single-quoted is fine.
>
> That's the fault of _ps1234.
>
> It's best to use compset -P and get to a point where _date_formats is
> called with $PREFIX only containing date formats and no prompt stuff.
>
> I finally worked out that the point of calling _default from _ps1234 is
> for print -P. That's _print's job to do that.

It was also so that nobody (weird?) would complain that PS1=/foo<tab>
stopped working, I think.

> +  compset -P '(\\|){' || pre=( -p "$bs{" )
> +  compset -S '(\\|)}*' || suf=( -S $bs\} )

Did you mean both $bs and \ here? You probably did, but doesn't hurt
to check :).

-- 
Mikael Magnusson



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