fuzzy_file_finder

A (slightly enhanced) implementation of TextMate's cmd-T lookup functionality, in Ruby, for embedding in other projects

  • 所有者: jamis/fuzzy_file_finder
  • 平台:
  • 許可證: Other
  • 分類:
  • 主題:
  • 喜歡:
    0
      比較:

Github星跟蹤圖

= FuzzyFileFinder

FuzzyFileFinder is a (somewhat improved) implementation of TextMate's "cmd-T" functionality. It allows you to search for a file by specifying a pattern of characters that appear in that file's name. Unlike TextMate, FuzzyFileFinder also lets you match against the file's directory, so you can more easily scope your search.

== FEATURES:

  • Quickly search directory trees for files
  • Avoids accidentally scanning huge directories by implementing a ceiling (default 10,000 entries)
  • Simple highlighting of matches to discover how a pattern matched

== SYNOPSIS:

In a nutshell:

require 'fuzzy_file_finder'

finder = FuzzyFileFinder.new

finder.search "app/blogcon" do, match, puts "[%5d] %s" % [match[:score] * 10000, match[:highlighted_path]]
end

matches = finder.find("app/blogcon").sort_by {, m, [-m[:score], m[:path] }
matches.each do, match, puts "[%5d] %s" % [match[:score] * 10000, match[:highlighted_path]]
end

See FuzzyFileFinder for more documentation, and links to further information.

== LICENSE:

All code, documentation, and related materials in this project are released into the PUBLIC DOMAIN. Usage, modification, and distribution are allowed without restriction.

主要指標

概覽
名稱與所有者jamis/fuzzy_file_finder
主編程語言Ruby
編程語言Ruby (語言數: 1)
平台
許可證Other
所有者活动
創建於2008-10-09 20:49:48
推送於2014-07-28 03:55:03
最后一次提交2014-07-27 21:55:03
發布數0
用户参与
星數143
關注者數4
派生數14
提交數19
已啟用問題?
問題數2
打開的問題數0
拉請求數0
打開的拉請求數0
關閉的拉請求數1
项目设置
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?