From 73bc2752dedfb8e2bd2439f47cddcafbe88663b6 Mon Sep 17 00:00:00 2001 From: Tom Willemse Date: Tue, 19 Feb 2019 00:13:51 -0800 Subject: [PATCH] =?UTF-8?q?Add=20a=20=E2=80=98grep-files-aliases=E2=80=99?= =?UTF-8?q?=20entry=20for=20JavaScript?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- oni-js2-mode.el | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/oni-js2-mode.el b/oni-js2-mode.el index eb5b66c..7932943 100644 --- a/oni-js2-mode.el +++ b/oni-js2-mode.el @@ -4,7 +4,7 @@ ;; Author: Tom Willemse ;; Keywords: local -;; Version: 20190218221547 +;; Version: 20190219001218 ;; Package-Requires: (oni-company js2-mode js2-refactor flycheck fill-column-indicator tern company-tern fic-mode) ;; This program is free software; you can redistribute it and/or modify @@ -31,6 +31,9 @@ (require 'js2-refactor) (require 'whitespace) +(eval-when-compile + (require 'grep)) + (defun oni-js2-mode-whitespace-mode () "Enable whitespace mode with only tabs showing." (setq-local whitespace-style '(face tabs)) @@ -56,7 +59,13 @@ (add-to-list 'company-backends 'company-tern) ;;;###autoload(with-eval-after-load 'js2-mode (require 'oni-js2-mode)) -;;;###autoload(add-to-list 'auto-mode-alist '("\\.js\\'" . js2-mode)) + +;;;###autoload +(add-to-list 'auto-mode-alist '("\\.js\\'" . js2-mode)) + +;;;###autoload +(with-eval-after-load 'grep + (add-to-list 'grep-files-aliases '("js" . "*.js *.jsx *.json"))) (provide 'oni-js2-mode) ;;; oni-js2-mode.el ends here