.emacs-my
changeset 1482 d74af7d75f19
parent 1481 31b541b9ce3e
child 1486 cf1175a9cd7b
equal deleted inserted replaced
1481:31b541b9ce3e 1482:d74af7d75f19
   821 `default-directory' with prefix."
   821 `default-directory' with prefix."
   822   (interactive (when current-prefix-arg (list (ag/read-from-minibuffer "Search string"))))
   822   (interactive (when current-prefix-arg (list (ag/read-from-minibuffer "Search string"))))
   823   (if str
   823   (if str
   824       (let ((current-prefix-arg nil)) (ag str default-directory))
   824       (let ((current-prefix-arg nil)) (ag str default-directory))
   825     (call-interactively #'ag-project)))
   825     (call-interactively #'ag-project)))
       
   826 
       
   827 (ignore-errors (require 'ag))
   826 
   828 
   827 (setq ag-highlight-search t)
   829 (setq ag-highlight-search t)
   828 (when (featurep 'ag)
   830 (when (featurep 'ag)
   829   (global-set-key [f7] 'my/ag))
   831   (global-set-key [f7] 'my/ag))
   830 
   832 
  3169 ;; go to end of buffer. To fix use code:
  3171 ;; go to end of buffer. To fix use code:
  3170 ;; (setq auto-mode-alist (rassq-delete-all 'js-mode auto-mode-alist))
  3172 ;; (setq auto-mode-alist (rassq-delete-all 'js-mode auto-mode-alist))
  3171 ;; (add-to-list 'auto-mode-alist '("\\.js$" . c++-mode))
  3173 ;; (add-to-list 'auto-mode-alist '("\\.js$" . c++-mode))
  3172 
  3174 
  3173 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  3175 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
       
  3176 (message "json")
       
  3177 
       
  3178 (defun my/json-mode-hook ()
       
  3179   (set (make-local-variable 'js-indent-level) 2))
       
  3180 (add-hook 'json-mode-hook #'my/json-mode-hook)
       
  3181 
       
  3182 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  3174 (message "bat file, batch")
  3183 (message "bat file, batch")
  3175 
  3184 
  3176 ;; loaded from 'generic-x.el'
  3185 ;; loaded from 'generic-x.el'
  3177 
  3186 
  3178 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  3187 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;