Skip to content

Commit

Permalink
Fix formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
svaante committed Sep 11, 2024
1 parent 96c549d commit 4096d71
Showing 1 changed file with 25 additions and 22 deletions.
47 changes: 25 additions & 22 deletions dape.el
Original file line number Diff line number Diff line change
Expand Up @@ -5211,28 +5211,31 @@ See `dape--config-mode-p' how \"valid\" is defined."
(add-hook 'after-change-functions
#'dape--minibuffer-hint nil t)
(dape--minibuffer-hint))
(pcase-let* ((str
(let ((history-add-new-input nil))
(read-from-minibuffer
"Run adapter: "
initial-contents
(let ((map (make-sparse-keymap)))
(set-keymap-parent map minibuffer-local-map)
(define-key map (kbd "C-M-i") #'completion-at-point)
(define-key map "\t" #'completion-at-point)
(define-key map (kbd "C-c C-k")
(lambda ()
(interactive)
(pcase-let* ((str (buffer-substring (minibuffer-prompt-end)
(point-max)))
(`(,key) (dape--config-from-string str t)))
(delete-region (minibuffer-prompt-end) (point-max))
(insert (format "%s" key) " "))))
map)
nil 'dape-history initial-contents)))
(`(,key ,config)
(dape--config-from-string (substring-no-properties str) t))
(evaled-config (dape--config-eval key config)))
(pcase-let*
((str
(let ((history-add-new-input nil))
(read-from-minibuffer
"Run adapter: "
initial-contents
(let ((map (make-sparse-keymap)))
(set-keymap-parent map minibuffer-local-map)
(define-key map (kbd "C-M-i") #'completion-at-point)
(define-key map "\t" #'completion-at-point)
(define-key map (kbd "C-c C-k")
(lambda ()
(interactive)
(pcase-let*
((str (buffer-substring (minibuffer-prompt-end)
(point-max)))
(`(,key) (dape--config-from-string str t)))
(delete-region (minibuffer-prompt-end)
(point-max))
(insert (format "%s" key) " "))))
map)
nil 'dape-history initial-contents)))
(`(,key ,config)
(dape--config-from-string (substring-no-properties str) t))
(evaled-config (dape--config-eval key config)))
(setq dape-history
(cons (dape--config-to-string key evaled-config)
dape-history))
Expand Down

0 comments on commit 4096d71

Please sign in to comment.