aboutsummaryrefslogtreecommitdiff
path: root/emacs/guix-prettify.el
diff options
context:
space:
mode:
Diffstat (limited to 'emacs/guix-prettify.el')
-rw-r--r--emacs/guix-prettify.el17
1 files changed, 9 insertions, 8 deletions
diff --git a/emacs/guix-prettify.el b/emacs/guix-prettify.el
index b01495c86b..24dfbb33e2 100644
--- a/emacs/guix-prettify.el
+++ b/emacs/guix-prettify.el
@@ -1,6 +1,6 @@
;;; guix-prettify.el --- Prettify Guix store file names
-;; Copyright © 2014 Alex Kost <alezost@gmail.com>
+;; Copyright © 2014, 2015 Alex Kost <alezost@gmail.com>
;; This file is part of GNU Guix.
@@ -47,9 +47,12 @@
;;; Code:
+(require 'guix-utils)
+
(defgroup guix-prettify nil
"Prettify Guix store file names."
:prefix "guix-prettify-"
+ :group 'guix
:group 'font-lock
:group 'convenience)
@@ -136,13 +139,11 @@ enabling/disabling `guix-prettify-mode'. If nil, do nothing.")
(remove-text-properties (point-min)
(point-max)
'(composition nil))
- (save-excursion
- (goto-char (point-min))
- (while (re-search-forward guix-prettify-regexp nil t)
- (remove-text-properties
- (match-beginning guix-prettify-regexp-group)
- (match-end guix-prettify-regexp-group)
- '(composition nil))))))))
+ (guix-while-search guix-prettify-regexp
+ (remove-text-properties
+ (match-beginning guix-prettify-regexp-group)
+ (match-end guix-prettify-regexp-group)
+ '(composition nil)))))))
;;;###autoload
(define-minor-mode guix-prettify-mode