branch: elpa/bash-completion
commit 432492adffbd7ef706041ebb0475cf4d1d1f87a6
Author: Stephane Zermatten <szerm...@gmx.net>
Commit: Stephane Zermatten <szerm...@gmx.net>

    feat: bash-completion-debug reports bash-completion scripts version
    
    With this change, bash-completion.el notes the value of
    BASH_COMPLETION_VERSINFO, set by the official bash completion scripts
    from https://github.com/scop/bash-completion This should help debug
    any future incompatibilities.
---
 bash-completion.el | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/bash-completion.el b/bash-completion.el
index 10d0841356..ec943173e0 100644
--- a/bash-completion.el
+++ b/bash-completion.el
@@ -445,6 +445,12 @@ returned."
                  (buffer-substring-no-properties
                   (point-min) (point-max))))
 
+  (bash-completion-send "echo -n ${BASH_COMPLETION_VERSINFO[*]}" process)
+  (process-put process 'bash-completion-scripts-version
+               (with-current-buffer (bash-completion--get-buffer process)
+                 (buffer-substring-no-properties
+                  (point-min) (point-max))))
+
   (bash-completion-send "bind -v 2>/dev/null" process)
   (process-put process 'completion-ignore-case
                (with-current-buffer (bash-completion--get-buffer process)
@@ -1645,6 +1651,7 @@ Return the status code of the command, as a number."
     (bash-completion--debug-print 'emacs-version emacs-version)
     (bash-completion--debug-print-procinfo 'bash-version) ; separate process
     (bash-completion--debug-print-info 'bash-version) ; one process
+    (bash-completion--debug-print-procinfo 'bash-completion-scripts-version)
     (bash-completion--debug-print-procinfo 'completion-ignore-case)
     (bash-completion--debug-print-info 'context)))
 

Reply via email to