Emacs Part 43
レス数が900を超えています。1000を超えると表示できなくなるよ。
0939名無しさん@お腹いっぱい。
2013/12/06(金) 23:38:05.74ありがとうございます。正常なら開かないのではなく正常なら閉じる、しかなさそうな感じですね。
gcc とかだとコンパイルエラーでも終了時のステータスが 0 だったので face で判断するのを書いてみました。
(add-hook 'compilation-finish-functions
(lambda (buffer msg)
(unless (with-current-buffer buffer
(let ((cur (point-min)) found)
(while (and cur (not found))
(setq found
(let ((face (get-text-property cur 'face)))
(memq 'compilation-error
(if (listp face)
face
(cons face nil)))))
(setq cur (next-property-change cur)))
found))
(when (get-buffer-window buffer)
(delete-window (get-buffer-window buffer))))))
レス数が900を超えています。1000を超えると表示できなくなるよ。