branch: externals/hyperbole
commit 98e88771f3c070f29a690499e544af3acc95af29
Merge: 9057ea0a8a 9278bc60aa
Author: Robert Weiner <[email protected]>
Commit: GitHub <[email protected]>
Merge branch 'master' into rsw
---
ChangeLog | 11 +++++++++++
Makefile | 8 ++++++--
hact.el | 3 ++-
hargs.el | 4 ++--
hbut.el | 4 ++--
hib-kbd.el | 8 ++++----
hmouse-tag.el | 6 +++---
hpath.el | 4 ++--
hsys-org.el | 5 ++++-
hyrolo.el | 1 +
hywiki.el | 9 +++++----
test/hywiki-tests.el | 39 ++++++++++++++++++++++-----------------
12 files changed, 64 insertions(+), 38 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index a4ce837222..e3f2b530c7 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+2024-06-22 Mats Lidell <[email protected]>
+
+* test/hywiki-tests.el
+ (hywiki-tests--get-page-list-when-new-wiki-directory): Verify cache is
+ empty for a new hywiki-directory.
+
+* Makefile (dockerized-update): Target to update (pull) the Emacs docker
+ image.
+ (dockerized): Copy source to docker so not local workspace is affected
+ when running targets in the docker environment.
+
2024-06-22 Bob Weiner <[email protected]>
* hyrolo.el (hyrolo-org-mode): Fix Org mode breakage with Emacs 30 and Org 9.7
diff --git a/Makefile b/Makefile
index b72306f74e..0c8e564b79 100644
--- a/Makefile
+++ b/Makefile
@@ -3,7 +3,7 @@
# Author: Bob Weiner
#
# Orig-Date: 15-Jun-94 at 03:42:38
-# Last-Mod: 19-May-24 at 10:58:02 by Bob Weiner
+# Last-Mod: 22-Jun-24 at 11:35:21 by Mats Lidell
#
# Copyright (C) 1994-2023 Free Software Foundation, Inc.
# See the file HY-COPY for license information.
@@ -563,7 +563,11 @@ DOCKER_VERSION = master-ci
endif
dockerized:
- docker run -v $$(pwd):/hyperbole -it silex/emacs:${DOCKER_VERSION} bash
-c "make -C hyperbole ${DOCKER_TARGETS}"
+ docker run -v $$(pwd):/hypb -it silex/emacs:${DOCKER_VERSION} bash -c
"cp -a /hypb /hyperbole && make -C hyperbole ${DOCKER_TARGETS}"
+
+# Update the docker image for the specified version of Emacs
+dockerized-update:
+ docker pull silex/emacs:${DOCKER_VERSION}
# Run with coverage. Run tests given by testspec and monitor the
# coverage for the specified file.
diff --git a/hact.el b/hact.el
index 3e66e7d477..553c0d4366 100644
--- a/hact.el
+++ b/hact.el
@@ -3,7 +3,7 @@
;; Author: Bob Weiner
;;
;; Orig-Date: 18-Sep-91 at 02:57:09
-;; Last-Mod: 23-May-24 at 23:18:43 by Bob Weiner
+;; Last-Mod: 22-Jun-24 at 22:50:10 by Mats Lidell
;;
;; SPDX-License-Identifier: GPL-3.0-or-later
;;
@@ -31,6 +31,7 @@
(declare-function hbut:is-p "hbut")
(declare-function hpath:absolute-arguments "hpath")
(declare-function hypb:indirect-function "hypb")
+(declare-function hargs:read-match "hargs")
;;; ************************************************************************
;;; Public variables
diff --git a/hargs.el b/hargs.el
index 114742cc47..58a39c4ff6 100644
--- a/hargs.el
+++ b/hargs.el
@@ -3,7 +3,7 @@
;; Author: Bob Weiner
;;
;; Orig-Date: 31-Oct-91 at 23:17:35
-;; Last-Mod: 29-May-24 at 00:57:17 by Bob Weiner
+;; Last-Mod: 22-Jun-24 at 22:53:41 by Mats Lidell
;;
;; SPDX-License-Identifier: GPL-3.0-or-later
;;
@@ -253,7 +253,7 @@ button key (no spaces)."
(defun hargs:delimited-p (start-delim end-delim
&optional start-regexp-flag end-regexp-flag
list-positions-flag exclude-regexp)
- "Call `hargs:delimited' with its `as-key' arg set to 'none.
+ "Call `hargs:delimited' with its `as-key' arg set to `none'.
See `hargs:delimited' for full documentation."
(hargs:delimited start-delim end-delim start-regexp-flag
end-regexp-flag list-positions-flag exclude-regexp 'none))
diff --git a/hbut.el b/hbut.el
index 5acf3bc783..501d92a11d 100644
--- a/hbut.el
+++ b/hbut.el
@@ -3,7 +3,7 @@
;; Author: Bob Weiner
;;
;; Orig-Date: 18-Sep-91 at 02:57:09
-;; Last-Mod: 25-May-24 at 16:30:50 by Bob Weiner
+;; Last-Mod: 23-Jun-24 at 00:11:37 by Mats Lidell
;;
;; SPDX-License-Identifier: GPL-3.0-or-later
;;
@@ -1229,7 +1229,7 @@ of point when desired.
Caller must have used (ibut:at-p) to create hbut:current prior to
calling this function. When KEY-SRC is given, this set's
-hbut:current's 'loc attribute to KEY-SRC."
+hbut:current's \\='loc attribute to KEY-SRC."
(if buffer
(if (bufferp buffer)
(set-buffer buffer)
diff --git a/hib-kbd.el b/hib-kbd.el
index 00a408bcd8..9d93b9e0db 100644
--- a/hib-kbd.el
+++ b/hib-kbd.el
@@ -3,7 +3,7 @@
;; Author: Bob Weiner
;;
;; Orig-Date: 22-Nov-91 at 01:37:57
-;; Last-Mod: 18-Feb-24 at 11:39:41 by Mats Lidell
+;; Last-Mod: 23-Jun-24 at 00:04:17 by Mats Lidell
;;
;; SPDX-License-Identifier: GPL-3.0-or-later
;;
@@ -105,7 +105,7 @@ Return t if the sequence appears to be valid, else nil."
"Execute a key series (series of key sequences) around point.
The key series is delimited by curly braces, {}. Key sequences
should be in human readable form, e.g. {C-x C-b}, or what
-`key-description' returns. Forms such as {\C-b}, {\^b}, and {^M}
+`key-description' returns. Forms such as {\\`C-b'}, {\\`^b'}, and {\\`^M'}
will not be recognized.
Any key sequence within the series must be a string of one of the following:
@@ -260,8 +260,8 @@ With optional prefix arg FULL, display full documentation
for command."
When STR is a curly-brace {} delimited key series, a
non-delimited, normalized form is returned, else nil. Key
sequences should be in human readable form, e.g. {\\`C-x' \\`C-b'}, or
-what `key-description' returns. Forms such as {\\`C-b'}, {\^b}, and
-{^M} will not be recognized.
+what `key-description' returns. Forms such as {\\`C-b'}, {\\`^b'}, and
+{\\`^M'} will not be recognized.
Any key sequence within the series must be a string of one of the following:
a Hyperbole minibuffer menu item key sequence,
diff --git a/hmouse-tag.el b/hmouse-tag.el
index a836235dcf..6fb7d3ffe6 100644
--- a/hmouse-tag.el
+++ b/hmouse-tag.el
@@ -3,7 +3,7 @@
;; Author: Bob Weiner
;;
;; Orig-Date: 24-Aug-91
-;; Last-Mod: 14-Apr-24 at 21:27:25 by Bob Weiner
+;; Last-Mod: 22-Jun-24 at 22:58:03 by Mats Lidell
;;
;; SPDX-License-Identifier: GPL-3.0-or-later
;;
@@ -1022,7 +1022,7 @@ It assumes that its caller has already checked that the
key was pressed in an
appropriate buffer and has moved the cursor to the selected buffer.
First, it tries to display the IDENTIFIER definition with
-the current 'xref' backend, which may be `eglot' or `etags' in which case
+the current `xref' backend, which may be `eglot' or `etags' in which case
Hyperbole walks up the current directory tree to find the nearest TAGS
file.
@@ -1501,7 +1501,7 @@ See the \"${hyperb:dir}/smart-clib-sym\" script for more
information."
"Jump to the single definition of TAG or list definition locations.
If NEXT is non-nil, jump to the next definition. Optional
LIST-OF-TAGS-TABLES are the tags tables to use when
-`xref-find-definitions' is called in a context where the 'etags'
+`xref-find-definitions' is called in a context where the `etags'
backend is used."
(when next (setq tag nil))
(let* ((tags-table-list (or list-of-tags-tables
diff --git a/hpath.el b/hpath.el
index d4abba08ae..e687b39590 100644
--- a/hpath.el
+++ b/hpath.el
@@ -3,7 +3,7 @@
;; Author: Bob Weiner
;;
;; Orig-Date: 1-Nov-91 at 00:44:23
-;; Last-Mod: 18-May-24 at 19:06:22 by Bob Weiner
+;; Last-Mod: 23-Jun-24 at 00:09:03 by Mats Lidell
;;
;; SPDX-License-Identifier: GPL-3.0-or-later
;;
@@ -2168,7 +2168,7 @@ point ends within the narrowed region."
(narrow-to-region omin omax)))))
(defun hpath:trim (path)
- "Return PATH with any [\" \t\n\r] characters trimmed from its start and end."
+ "Return PATH with any [\" \\t\\n\\r] characters trimmed from its start and
end."
;; Trim only matching starting and ending quoted double quotes (must
;; be a single line string).
(setq path (string-trim path))
diff --git a/hsys-org.el b/hsys-org.el
index 13543dd44c..11dbde4471 100644
--- a/hsys-org.el
+++ b/hsys-org.el
@@ -3,7 +3,7 @@
;; Author: Bob Weiner
;;
;; Orig-Date: 2-Jul-16 at 14:54:14
-;; Last-Mod: 9-Jun-24 at 12:46:05 by Bob Weiner
+;; Last-Mod: 22-Jun-24 at 23:43:08 by Mats Lidell
;;
;; SPDX-License-Identifier: GPL-3.0-or-later
;;
@@ -45,6 +45,7 @@
;;; ************************************************************************
(declare-function consult-grep "ext:consult")
+(declare-function consult-ripgrep "ext:consult")
(defcustom hsys-org-consult-grep-func
(cond ((executable-find "rg")
@@ -56,6 +57,7 @@
(defvar hyperbole-mode-map) ; "hyperbole.el"
(defvar org--inhibit-version-check) ; "org-macs.el"
+(defvar hywiki-org-link-type-required) ; "hywiki.el"
(declare-function org-babel-get-src-block-info "org-babel")
(declare-function org-fold-show-context "org-fold")
@@ -71,6 +73,7 @@
(declare-function hkey-either "hmouse-drv")
(declare-function find-library-name "find-func")
+(declare-function hyperb:stack-frame "hversion.el")
;;;###autoload
(defcustom hsys-org-enable-smart-keys 'unset
diff --git a/hyrolo.el b/hyrolo.el
index 12b7303363..de5e3a9321 100644
--- a/hyrolo.el
+++ b/hyrolo.el
@@ -135,6 +135,7 @@
;; Forward declarations
(defvar consult-grep-args)
(defvar consult-ripgrep-args)
+(defvar consult-async-split-style)
(defvar google-contacts-expire-time)
(defvar google-contacts-history)
(defvar google-contacts-query-string)
diff --git a/hywiki.el b/hywiki.el
index 57ac0d7076..89ca51790c 100644
--- a/hywiki.el
+++ b/hywiki.el
@@ -3,7 +3,7 @@
;; Author: Bob Weiner
;;
;; Orig-Date: 21-Apr-24 at 22:41:13
-;; Last-Mod: 19-Jun-24 at 15:08:31 by Bob Weiner
+;; Last-Mod: 23-Jun-24 at 00:12:37 by Mats Lidell
;;
;; SPDX-License-Identifier: GPL-3.0-or-later
;;
@@ -116,6 +116,7 @@
;;; Public declarations
;;; ************************************************************************
+(defvar org-agenda-buffer-tmp-name) ;; "org-agenda.el"
(declare-function org-link-store-props "ol" (&rest plist))
;;; ************************************************************************
@@ -164,8 +165,8 @@ Use nil for no HyWiki mode indicator."
(defvar-local hywiki-buffer-highlighted-state nil
"State of HyWikiWords highlighting in the associated buffer.
-'h means the buffer was already highlighted;
-'d means the buffer was dehighlighted;
+\\='h means the buffer was already highlighted;
+\\='d means the buffer was dehighlighted;
nil means no full buffer highlighting has occurred.")
(defvar hywiki-non-character-commands
@@ -430,7 +431,7 @@ call)
By default, create any non-existent page. With optional
PROMPT-FLAG t, prompt to create if non-existent. If PROMPT-FLAG
-is 'exists, return nil unless the page already exists. After
+is \\='exists, return nil unless the page already exists. After
successfully finding a page and reading it into a buffer, run
`hywiki-find-page-hook'."
(interactive (list (completing-read "Find HyWiki page: "
(hywiki-get-page-list))))
diff --git a/test/hywiki-tests.el b/test/hywiki-tests.el
index fda0abd831..99f3c01dda 100644
--- a/test/hywiki-tests.el
+++ b/test/hywiki-tests.el
@@ -3,7 +3,7 @@
;; Author: Mats Lidell
;;
;; Orig-Date: 18-May-24 at 23:59:48
-;; Last-Mod: 22-Jun-24 at 00:47:02 by Bob Weiner
+;; Last-Mod: 22-Jun-24 at 18:56:31 by Mats Lidell
;;
;; SPDX-License-Identifier: GPL-3.0-or-later
;;
@@ -26,8 +26,7 @@
"Verify add page creates file in wiki folder and sets hash table."
(let* ((hsys-org-enable-smart-keys t)
(hywiki-directory (make-temp-file "hywiki" t))
- (hywiki-page-file (expand-file-name "WikiWord.org" hywiki-directory))
- (hywiki--pages-hasht nil))
+ (hywiki-page-file (expand-file-name "WikiWord.org" hywiki-directory)))
(unwind-protect
(mocklet (((make-empty-file (expand-file-name "WikiWord.org"
hywiki-directory) t) => t))
(should (string= hywiki-page-file
@@ -45,8 +44,7 @@
;; added error cleanup till later if it is even needed!? No file
;; should be created so only happens on error!? (If this is
;; considered an error case that is.)
- (let ((hywiki-directory (make-temp-file "hywiki" t))
- (hywiki--pages-hasht nil))
+ (let ((hywiki-directory (make-temp-file "hywiki" t)))
(unwind-protect
(should-error (hywiki-add-page "notawikiword"))
(hy-delete-dir-and-buffer hywiki-directory))))
@@ -56,7 +54,6 @@
(defvar wikifile)
(let ((hsys-org-enable-smart-keys t)
(hywiki-directory (make-temp-file "hywiki" t))
- (hywiki--pages-hasht nil)
(wikifile (make-temp-file "wikifile")))
(hywiki-mode -1)
(unwind-protect
@@ -70,8 +67,7 @@
(ert-deftest hywiki-tests--not-a-wikiword-unless-in-hywiki-mode ()
"Verify WikiWord is not a WikiWord unless in `hywiki-mode'."
(let ((hsys-org-enable-smart-keys t)
- (hywiki-directory (make-temp-file "hywiki" t))
- (hywiki--pages-hasht nil))
+ (hywiki-directory (make-temp-file "hywiki" t)))
(unwind-protect
(with-temp-buffer
(hywiki-mode 0)
@@ -85,8 +81,7 @@
(ert-deftest hywiki-tests--at-wikiword-finds-word-and-section ()
"Verify `hywiki-word-at' finds WikiWord and section if available."
- (let ((hywiki-directory (make-temp-file "hywiki" t))
- (hywiki--pages-hasht nil))
+ (let ((hywiki-directory (make-temp-file "hywiki" t)))
(unwind-protect
(with-temp-buffer
(hywiki-mode)
@@ -125,7 +120,6 @@
(ert-deftest hywiki-tests--in-page-p ()
"Verify `hywiki-in-page-p' identifies a page in and outside of the wiki
directory."
(let* ((hywiki-directory (make-temp-file "hywiki" t))
- (hywiki--pages-hasht nil)
(wiki-page (hywiki-add-page "WikiWord"))
(no-wiki-page (make-temp-file "hypb")))
(unwind-protect
@@ -140,7 +134,6 @@
(ert-deftest hywiki-tests--active-in-current-buffer-p ()
"Verify `hywiki-active-in-current-buffer-p'."
(let* ((hywiki-directory (make-temp-file "hywiki" t))
- (hywiki--pages-hasht nil)
(wiki-page (hywiki-add-page "WikiWord"))
(hywiki-word-highlight-flag t))
(unwind-protect
@@ -178,7 +171,6 @@
(ert-deftest hywiki-tests--get-page-list ()
"Verify `hywiki-get-page-list' returns one WikiWord."
(let* ((hywiki-directory (make-temp-file "hywiki" t))
- (hywiki--pages-hasht nil)
(wiki-page (hywiki-add-page "WikiWord")))
(unwind-protect
(progn
@@ -191,7 +183,6 @@
(ert-deftest hywiki-tests--get-page-list-multiple-words ()
"Verify `hywiki-get-page-list' returns multiple WikiWords."
(let* ((hywiki-directory (make-temp-file "hywiki" t))
- (hywiki--pages-hasht nil)
(basename "WikiWord")
(wiki-page-list nil))
(unwind-protect
@@ -204,6 +195,22 @@
(hy-delete-files-and-buffers wiki-page-list)
(hy-delete-dir-and-buffer hywiki-directory))))
+(ert-deftest hywiki-tests--get-page-list-when-new-wiki-directory ()
+ "Verify `hywiki-get-page-list' is empty for new `hywiki-directory'."
+ (let* ((hywiki-directory (make-temp-file "hywiki" t))
+ (wiki-page (hywiki-add-page "WikiWord")))
+ (unwind-protect
+ (progn
+ (should (= 1 (length (hywiki-get-page-list))))
+ (let ((hywiki-directory (make-temp-file "hywiki" t)))
+ (unwind-protect
+ (progn
+ (should (hash-empty-p (hywiki-get-page-hasht)))
+ (should (= 0 (length (hywiki-get-page-list)))))
+ (hy-delete-dir-and-buffer hywiki-directory))))
+ (hy-delete-file-and-buffer wiki-page)
+ (hy-delete-dir-and-buffer hywiki-directory))))
+
;; Following two test cases for verifying proper face is some what
;; experimental. They need to be run in interactive mode and with the
;; help of hy-test-helpers:consume-input-events it seems the property
@@ -214,7 +221,6 @@
(skip-unless (not noninteractive))
(let* ((hsys-org-enable-smart-keys t)
(hywiki-directory (make-temp-file "hywiki" t))
- (hywiki--pages-hasht nil)
(wikipage (hywiki-add-page "WikiWord")))
(unwind-protect
(with-temp-buffer
@@ -233,8 +239,7 @@
"Verify WikiWord for no wiki page does not get face property
hywiki-word-face."
(skip-unless (not noninteractive))
(let* ((hsys-org-enable-smart-keys t)
- (hywiki-directory (make-temp-file "hywiki" t))
- (hywiki--pages-hasht nil))
+ (hywiki-directory (make-temp-file "hywiki" t)))
(unwind-protect
(with-temp-buffer
(let ((buffer (current-buffer)))