comparison .elisp/textmate.el @ 331:ecb85d3ba960

textmate.el: use hg locate for speed
author Augie Fackler <raf@durin42.com>
date Tue, 11 Mar 2014 14:16:42 -0400
parents 629b500e1276
children 577c824c2288
comparison
equal deleted inserted replaced
330:629b500e1276 331:ecb85d3ba960
319 (incpat (if pattern pattern "*")) 319 (incpat (if pattern pattern "*"))
320 (type (textmate-project-root-type (textmate-project-root))) 320 (type (textmate-project-root-type (textmate-project-root)))
321 (command 321 (command
322 (cond ((not (string= type "unknown")) 322 (cond ((not (string= type "unknown"))
323 (concat (cond ((string= type "git") "git ls-files") 323 (concat (cond ((string= type "git") "git ls-files")
324 ((string= type "hg") "hg manifest")) 324 ((string= type "hg") "hg locate 'set:added() or modified() or clean()'"))
325 (if *textmate-vcs-exclude* 325 (if *textmate-vcs-exclude*
326 (concat " | egrep --color=never -v " 326 (concat " | egrep --color=never -v "
327 (shell-quote-argument *textmate-vcs-exclude*)) 327 (shell-quote-argument *textmate-vcs-exclude*))
328 "") 328 "")
329 " | xargs egrep --color=never -nR " 329 " | xargs egrep --color=never -n "
330 (if pattern (concat " --include='" pattern "' ") "") 330 (if pattern (concat " --include='" pattern "' ") "")
331 " -- " 331 " -- "
332 (shell-quote-argument re))) 332 (shell-quote-argument re)))
333 (t (concat "egrep --color=never -nR --exclude='" 333 (t (concat "egrep --color=never -nR --exclude='"
334 *textmate-gf-exclude* 334 *textmate-gf-exclude*