Top / emacs / ag

cygwin のag

ver15までは,Windows + cygwin でビルド可能.ver16以降は cygwinのdirentのメンバにd_reclenがないため,ビルド不可

ag.elを,Windowsで使用する.

正規表現と,環境変数を調整する.未デバッグのメモ.

--- before      2013-12-28 13:28:01.682729400 +0900
+++ after       2013-12-28 13:27:55.888398000 +0900
@@ -103,7 +103,9 @@
         ;; handle weird file names (with colons in them) as well as possible.
         ;; E.g. we use [1-9][0-9]* rather than [0-9]+ so as to accept ":034:"
         ;; in file names.
-        (pttrn '("^\\([^:\n]+?\\):\\([1-9][0-9]*\\):\\([1-9][0-9]*\\):" 1 2 3)))
+        ;; (pttrn '("^\\([^:\n]+?\\):\\([1-9][0-9]*\\):\\([1-9][0-9]*\\):" 1 2 3)))
+        ;; for Windows path
+        (pttrn '("^\\([a-zA-Z]:/[^:\n]+?\\):\\([1-9][0-9]*\\):\\([1-9][0-9]*\\):" 1 2 3) )
     (set (make-local-variable 'compilation-error-regexp-alist) (list smbl))
     (set (make-local-variable 'compilation-error-regexp-alist-alist) (list (cons smbl pttrn))))
   (set (make-local-variable 'compilation-error-face) 'ag-hit-face)
@@ -135,6 +137,7 @@
       (setq arguments (append `("--file-search-regex" ,file-regex) arguments)))
     (unless (file-exists-p default-directory)
       (error "No such directory %s" default-directory))
+    (message (setenv "LANG" "ja_JP.sjis"))
     (compilation-start
      (mapconcat 'shell-quote-argument
                 (append '("ag") arguments (list string "."))
Link: MenuBar(92d) ,
Site admin: kam1610, PukiWiki 1.4.7 Copyright © 2001-2006 PukiWiki Developers Team. License is GPL.
Based on "PukiWiki" 1.3 by yu-ji. Powered by PHP 5.2.17.