emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] externals/coterm 34d8808 54/80: Improve less prompt regexp


From: ELPA Syncer
Subject: [elpa] externals/coterm 34d8808 54/80: Improve less prompt regexp
Date: Wed, 13 Oct 2021 18:57:35 -0400 (EDT)

branch: externals/coterm
commit 34d8808e556843b2ab007919c61ec8e5b256dbcb
Author: m <>
Commit: m <>

    Improve less prompt regexp
---
 coterm.el | 29 +++++++++++++++--------------
 1 file changed, 15 insertions(+), 14 deletions(-)

diff --git a/coterm.el b/coterm.el
index f91ebcd..78491cd 100644
--- a/coterm.el
+++ b/coterm.el
@@ -241,19 +241,20 @@ If point is not on process mark, leave `coterm-char-mode' 
and
     (let ((opoint (point)))
       (forward-line 0)
       (prog1
-          (and
-           (looking-at
-            (concat
-             ":\\|"
-             "(END)\\|"
-             "byte [0-9]+\\|"
-             "100%\\|"
-             "\\(?:[^\n]* \\)?" "[0-9]?[0-9]%\\|"
-             "[^\n]*(press h for help or q to quit)"))
-           (when (= opoint (match-end 0))
-             (unless coterm-char-mode (coterm-char-mode 1))
-             (unless coterm-scroll-snap-mode (coterm-scroll-snap-mode 1))
-             t))
+          (when (looking-at
+                 (concat
+                  "\\(?:"
+                  ":\\|"
+                  "(END)\\|"
+                  "byte [0-9]+\\|"
+                  "100%\\|"
+                  "\\(?:.* \\)?" "[0-9]?[0-9]%\\|"
+                  ".*(press h for help or q to quit)\\|"
+                  ".*(press RETURN)"
+                  "\\)\\'"))
+            (unless coterm-char-mode (coterm-char-mode 1))
+            (unless coterm-scroll-snap-mode (coterm-scroll-snap-mode 1))
+            t)
         (goto-char opoint)))))
 
 (defun coterm--auto-char-mpv-prompt ()
@@ -291,7 +292,7 @@ active if these status prompt erasures are detected."
     (let ((opoint (point)))
       (forward-line -1)
       (prog1 (looking-at
-              (concat "\\(?:[^\n]*\n\\)?"
+              (concat "\\(?:.*\n\\)?"
                       "A?V?: "
                       "[0-9][0-9]:[0-9][0-9]:[0-9][0-9] / "
                       "[0-9][0-9]:[0-9][0-9]:[0-9][0-9] "



reply via email to

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