k1LoW / emacs-ansible

GNU General Public License v2.0
116 stars 31 forks source link

BREAKS !!! compilation mode regex parsing for other programming languages. #49

Open farazshaikh opened 6 months ago

farazshaikh commented 6 months ago

Emacs 29.1

Bisected this behavior, where ansible package broke "output parsing" of compilation buffer output parsing for rust.

Ansible modifies/sets the following variable in "some way" that is breaks compilation parsing for other languages:

compilation-error-regexp-alist-alist is a variable defined in ‘compile.el’.

Its value is shown below.

Alist of values for ‘compilation-error-regexp-alist’.

Value:
((ansible "^\\(.*?\\):\\([0-9]+\\)" 1 2)        << Culprit

(use-package ansible :init (add-hook 'yaml-mode-hook '(lambda () (ansible 1)))) (use-package company-ansible)

yurikhan commented 3 months ago

Also noticed this. ansible.el defines a regexp that matches almost anything and adds it at the beginning of compilation-error-regexp-alist, so it matches before anything else has a chance to match.