a
(cl-defun %eshell-better-prompt-split (strings
&optional (eshell-better-prompt-limit 10)
&aux (next "") newlist (len 0))
(do-sublists* (sublist strings (nreverse newlist))
(aand cadr (setq next it))
(push car newlist)
(incf len (+ 2 (length next)))
(and cdr (not (eq strings sublist))
(< eshell-better-prompt-limit len)
(push "\n" newlist))))
(используется мой макрос, но можно догадаться, что он делает)