Skip to content

Instantly share code, notes, and snippets.

@leoliu
Last active January 3, 2016 12:59
Show Gist options
  • Save leoliu/8466231 to your computer and use it in GitHub Desktop.
Save leoliu/8466231 to your computer and use it in GitHub Desktop.
ack.diff
diff --git a/ack.el b/ack.el
index 3b7e25dc..8eb1fa4d 100644
--- a/ack.el
+++ b/ack.el
@@ -282,7 +282,11 @@ (define-compilation-mode ack-mode "Ack"
nil '(((lambda (limit)
(let ((beg (marker-position ack--ansi-color-last-marker)))
(move-marker ack--ansi-color-last-marker limit)
- (ansi-color-apply-on-region beg ack--ansi-color-last-marker))
+ (ansi-color-apply-on-region beg ack--ansi-color-last-marker)
+ ;; Issue https://github.com/leoliu/ack-el/pull/3
+ (goto-char beg)
+ (while (re-search-forward "\x1b\\[K" ack--ansi-color-last-marker t)
+ (replace-match "")))
nil)))))
(define-key ack-mode-map "\C-o" #'ack-mode-display-match))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment