emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [elpa] externals/zuul b0cc517949: Make it easier to customize sort a


From: Philip Kaludercic
Subject: Re: [elpa] externals/zuul b0cc517949: Make it easier to customize sort and face
Date: Fri, 07 Oct 2022 14:47:54 +0000

ELPA Syncer <elpasync@gnu.org> writes:

>
> branch: externals/zuul
> commit b0cc51794991abf749b4fc77aace17f0fe98411d
> Author: Niklas Eklund <niklas.eklund@posteo.net>
> Commit: Niklas Eklund <niklas.eklund@posteo.net>
>
>     Make it easier to customize sort and face
> ---
>  zuul.el | 57 ++++++++++++++++++++++++++++++++-------------------------
>  1 file changed, 32 insertions(+), 25 deletions(-)
>
> diff --git a/zuul.el b/zuul.el
> index 7503b910a9..439fa4ff45 100644
> --- a/zuul.el
> +++ b/zuul.el
> @@ -164,6 +164,31 @@ Each entry in the list is a property list with the 
> following properties:
>    :group 'zuul
>    :type 'boolean)
>  
> +(defcustom zuul-sort-priority-functions
> +  `((lambda (it)
> +      (if-let ((start-time (zuul--start-time it)))
> +          (float-time (date-to-time start-time))
> +        0.0))
> +    (lambda (it)
> +      (pcase (zuul--status it)
> +        ("SUCCESS" 0)
> +        ("QUEUED" 1)
> +        ("FAILURE" 3)
> +        (_ 2)))
> +    (lambda (it)
> +      (pcase (let-alist (zuul-data it) .pipeline)
> +        ("check" 1)
> +        ("gate" 2)
> +        (_ 3))))

The lambda expressions in this list should probably not be quoted.  It
would be preferable to either write it out as (list (lambda (it) ...))
or give the functions names.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]