Skip to content

Instantly share code, notes, and snippets.

(provide 'google-eldoc)
(require 'eldoc)
(require 'crxel)
(defun google-eldoc-turn-on-eldoc-mode ()
"Enable google-eldoc-mode"
(interactive)
(set (make-local-variable 'eldoc-documentation-function)
'google-eldoc-search-current-symbol-info)
(turn-on-eldoc-mode))
(require 'vc-git)
(provide 'auto-update-gtags)
(defvar auto-update-gtags/interval (* 60 60) "interval seconds")
(defvar auto-update-gtags/command "gtags")
(defun auto-update-gtags/file-need-update-p (file interval)
(and (file-writable-p file)
(or (not (file-exists-p file))
(> (- (float-time) (float-time (nth 5 (file-attributes file))))
interval))))
@mechairoi
mechairoi / .ctags
Created February 18, 2014 01:57
.ctags for angualr js
--regex-javascript=/\.controller[ \t]*\([ \t]*['"]([A-Za-z0-9_.]+)['"][ \t]*,/\1/C,controller/i
--regex-javascript=/\.filter[ \t]*\([ \t]*['"]([A-Za-z0-9_.]+)['"][ \t]*,/\1/F,filter/i
--regex-javascript=/\.module[ \t]*\([ \t]*['"]([A-Za-z0-9_.]+)['"][ \t]*,/\1/M,module/i
--regex-javascript=/\.directive[ \t]*\([ \t]*['"]([A-Za-z0-9_.]+)['"][ \t]*,/\1/D,directive/i
--regex-javascript=/\.factory[ \t]*\([ \t]*['"]([A-Za-z0-9_.]+)['"][ \t]*,/\1/F,factory/i
--regex-javascript=/\.value[ \t]*\([ \t]*['"]([A-Za-z0-9_.]+)['"][ \t]*,/\1/V,value/i
--regex-javascript=/\.provider[ \t]*\([ \t]*['"]([A-Za-z0-9_.]+)['"][ \t]*,/\1/P,provider/i
--regex-javascript=/\.constant[ \t]*\([ \t]*['"]([A-Za-z0-9_.]+)['"][ \t]*,/\1/C,constant/i
--regex-javascript=/\.config[ \t]*\([ \t]*['"]([A-Za-z0-9_.]+)['"][ \t]*,/\1/C,config/i
"loadavg5",
"memory.total",
"memory.free",
"memory.buffers",
"memory.cached",
"memory.swap_cached",
"memory.active",
"memory.inactive",
"memory.swap_total",
"memory.swap_free",
(require 'vc-git)
(defun git-browse-remote-at-point (rev)
(interactive "P")
(let* ((root (vc-git-root buffer-file-name))
(default-directory root)
(line (if (use-region-p)
(format "%d,%d"
(line-number-at-pos (region-beginning))
(line-number-at-pos (region-end)))
#!/usr/bin/env bash
# Put followings your .tmux.conf
#
# bind ^T run-shell tmux-ghq
#
set -e
fzfcmd="fzf-tmux -d${FZF_TMUX_HEIGHT:-40%} -e +s"