Created
November 8, 2012 17:42
-
-
Save ngn999/4040317 to your computer and use it in GitHub Desktop.
query mode
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;;; query-mode.el --- a mode for view our access log | |
;; query example | |
;; /bin/search?auction?user_id=79586&statistic=field=pidvid,count=500&n=4&s=2 | |
;; Author : ngn <[email protected]> | |
;; URL : https://gist.github.com/4040317 | |
;; Version : 0.1 | |
;; Keywords : query, url | |
;; This file is not part of GNU Emacs. | |
(setq myKeywords | |
'( | |
("&" . font-lock-string-face) | |
("=[^&]*" . font-lock-function-name-face) | |
("/.*\\?" . font-lock-string-face) | |
)) | |
(define-derived-mode query-mode fundamental-mode | |
(setq font-lock-defaults '(myKeywords)) | |
(setq mode-name "Query")) | |
(provide 'query-mode) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment