branch: elpa/idris-mode commit 66daf810c7886730727497fdcee54dfde4853e12 Author: Marek L <nospam.ke...@gmail.com> Commit: Marek L <nospam.ke...@gmail.com>
Ensure restart of Idris connection takes into account change in `idris-hole-show-on-load` variable. Why: This improves reliability of test suite and after all improves also user experience. --- inferior-idris.el | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/inferior-idris.el b/inferior-idris.el index 08aeb843c8..a300c72722 100644 --- a/inferior-idris.el +++ b/inferior-idris.el @@ -107,7 +107,10 @@ This is maintained to restart Idris when the arguments change.") (add-hook 'idris-event-hooks 'idris-warning-event-hook-function) (add-hook 'idris-event-hooks 'idris-prover-event-hook-function) - (unless idris-hole-show-on-load + (if idris-hole-show-on-load + (progn + (add-hook 'idris-load-file-success-hook 'idris-list-holes) + (add-hook 'idris-prover-success-hook 'idris-list-holes)) (remove-hook 'idris-load-file-success-hook 'idris-list-holes-on-load) (remove-hook 'idris-load-file-success-hook 'idris-list-holes) ;; TODO: In future decouple prover sucess hook from being affected by