瀏覽代碼

Use bfs if available

master
10sr 5 年之前
父節點
當前提交
8384a1431b
簽署人: 10sr GPG 金鑰 ID: C384BB17CBB19347
共有 1 個檔案被更改,包括 11 行新增7 行删除
  1. +11
    -7
      emacs.el

+ 11
- 7
emacs.el 查看文件

@@ -739,14 +739,18 @@ found, otherwise returns nil."
;; (set-variable 'fzf/executable "sk")
;; (set-variable 'fzf/args "--color bw --print-query")
;; Modified from hardcoded default to include directories, hidden files, and root directory
(let ((defcmd (concat "set -o pipefail; "
"command find -L . "
"\\( -fstype 'sysfs' -o -fstype 'devfs' -o -fstype 'devtmpfs' -o -fstype 'proc' \\) -prune "
"-o -print 2> /dev/null "
"| "
"sed -e 's|^\\./||'")))
(let* ((find (if (executable-find "bfs")
;; Breadth-first find https://github.com/tavianator/bfs
"bfs"
"find"))
(defcmd (concat "set -o pipefail; "
"command " find " -L . "
"\\( -fstype 'sysfs' -o -fstype 'devfs' -o -fstype 'devtmpfs' -o -fstype 'proc' \\) -prune "
"-o -print 2> /dev/null "
"| "
"sed -e 's|^\\./||'")))
(setenv "FZF_DEFAULT_COMMAND" defcmd))
;; (define-key ctl-x-map (kbd "C-f") 'fzf)
(define-key ctl-x-map (kbd "C-f") 'fzf)
)

(when (safe-require-or-eval 'recently)


Loading…
取消
儲存