]> git.eshelyaron.com Git - emacs.git/commit
Optionally signal an error if an Eshell predicate fails to match anything
authorJim Porter <jporterbugs@gmail.com>
Sun, 26 Jun 2022 03:05:57 +0000 (20:05 -0700)
committerLars Ingebrigtsen <larsi@gnus.org>
Sun, 26 Jun 2022 14:51:21 +0000 (16:51 +0200)
commit598d7c5d1c10bfb161cb53aa76d480864414487c
tree42d650e0476b281145c650dbe095e8e651b60a18
parentb637d9c0750fde8810058a153d964b6c70e0f577
Optionally signal an error if an Eshell predicate fails to match anything

* lisp/eshell/em-pred.el (eshell-error-if-no-glob): Declare it.
(eshell-apply-modifiers): Add STRING-DESC argument and signal an error
if there are no matches and 'eshell-error-if-no-glob' is set.
(eshell-parse-arg-modifier): Pass modifier string to
'eshell-apply-modifiers'.

* test/lisp/eshell/em-pred-tests.el (eshell-eval-predicate): Simplify.
(em-pred-test/no-matches): New test.

* doc/misc/eshell.texi (Bugs and ideas): Remove todo entry about this
change.
doc/misc/eshell.texi
lisp/eshell/em-pred.el
test/lisp/eshell/em-pred-tests.el