public
Description: A (slightly enhanced) implementation of TextMate's cmd-T lookup functionality, in Ruby, for embedding in other projects
Homepage:
Clone URL: git://github.com/jamis/fuzzy_file_finder.git
Click here to lend your support to: fuzzy_file_finder and make a donation at www.pledgie.com !
jamis (author)
Sun Oct 12 19:48:29 -0700 2008
commit  6328948cbeed388d0f8dd10f28c468b109840926
tree    56c00d959b15a15f108d9be67f875bb0c60a8068
parent  a1dfc2ed63763a93b67eea38eb274ba6d8abc939
name age message
file .gitignore Fri Oct 10 22:55:52 -0700 2008 Added support for multiple search roots to Fuzz... [Kevin]
file LICENSE Thu Oct 09 13:43:01 -0700 2008 initial commit [jamis]
file Manifest Thu Oct 09 13:43:01 -0700 2008 initial commit [jamis]
file README.rdoc Thu Oct 09 13:43:01 -0700 2008 initial commit [jamis]
file Rakefile Thu Oct 09 13:43:01 -0700 2008 initial commit [jamis]
file fuzzy_file_finder.gemspec Sun Oct 12 19:48:29 -0700 2008 version bump [jamis]
directory lib/ Loading commit data...
README.rdoc

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.

INSTALL:

LICENSE:

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