GithubHelp home page GithubHelp logo

subtlegradient / gotofile.tmbundle Goto Github PK

View Code? Open in Web Editor NEW

This project forked from amiel/gotofile.tmbundle

2.0 3.0 0.0 193 KB

Bringing Jamis's FuzzyFileFinder back to textmate.

License: Other

Ruby 100.00%

gotofile.tmbundle's Introduction

Outline

“GoToFile” imitates TextMate’s “Go to File…” ⌘T functionality see here. In addition it is possible to narrow down the list of files by considering (parts of) the file path using '/' as a delimiter.

Furthermore it is not only possible to open the selected file in TextMate but also to:

  • open the selected file in the default application (by using “open”)
  • activate QuickLook
  • insert the relative path from the current file (that file which had the focus while invoking “GoToFile”) to the selected one
  • insert the absolute path.

The list of found files is sorted by the score which is calculated inside of Jamis Buck's “Fuzzy File Finder” routine. If the letters typed in match word prefixes (as mf does in my_file.txt), the match is usually prioritised. The maximum number of outputted files is set to 100 (can be changed in “FileFinder.rb” line 4).

To ignore certain files add a TextMate shell variable called TM_FUZZYFINDER_IGNORE, in it put the file globs separated by commas. For example: '*.pyc,*.zip,*.gz,*.bz,*.tar,*.jpg,*.png,*.gif,*.avi,*.wmv,*.ogg,*.mp3,*.mov'.

As default there is a limit of 10.000 files in the tree structure. To increase/decrease that maximum number add the TextMate shell variable TM_FUZZYFINDER_CEILING and set it accordingly.

This GUI makes usage of makes usage of Jamis Buck's “Fuzzy File Finder” and was inspired by Amiel Martin's “FuzzyFileFinder” bundle which a few code fragments are taken from.

Installation

  • by using “GetBundles”

  • by using “git”:

cd ~/Library/Application\ Support/TextMate/Bundles/
git clone git://github.com/amiel/gotofile.tmbundle.git GoToFile.tmbundle
  • by downloading this zip archive, decompressing it, renaming it to “GoToFile.tmbundle”, and finally double-clicking at it

Usage

⇧⌘K invokes “GoToFile”. The root directory will be taken from $TM_PROJECT_DIRECTORY || $TM_DIRECTORY || current directory. “GoToFile” won't work on unsaved documents. There is a mouse-over event to display the entire file path.

Input Field

Type characters in order to narrow down the list of files. The dialogue will be updated while typing. To search only in certain folders type for instance: s/rb or s/li/mm etc. If the letters match word prefixes (as mf does in my_file.txt), the match is usually prioritized.

If you would like to search for the file and then narrow down to subdirectory, you can type rb\s or mm\li\s.

Normally spaces are ignored. If one wants to look for a space one has to escape the space: \␣

Shortcuts

  • CLICK or ↩ opens the file in TextMate
  • ⌥ CLICK or ⌥↩ opens the file with the default application
  • ⇧ CLICK or ⇧↩ inserts the relative file path
  • ⇧⌥ CLICK or ⇧⌥↩ inserts the absolute file path
  • SPACE toggles the QuickLook mode (Leopard only)
  • ⌥ SPACE adds an (escaped) space character in the search query
  • ↑ and ↓ resp. ⇥ and ⇧⇥ navigates through the list of files
  • ^F sets the focus to the input field
  • ⌘W or ESC closes the “GoToFile” window

Official Git Repos

Can be found here: http://github.com/amiel/gotofile.tmbundle

ToDo / wish list

  • window should close when a file is opened (maybe configurable as it seems that some people like that it stays open)
  • take out duplicate files
  • clean up javascript (incorporate sizzle or jquery)

also check out the todo list on the github wiki

Contributions

Date: Feb 26 2009

-  Jamis Buck — fuzzy_file_finder library - [email protected] 
-  Amiel Martin  [email protected]
-  Hans-Jörg Bibiko  [email protected]
-  Eric Doughty-Papassideris  github:ddlsmurf
-  Travis Jeffery  [email protected]
-  Eric O'Connell   github:drd
-  Nathan Carnes  github:nathancarnes

gotofile.tmbundle's People

Contributors

ddlsmurf avatar subtlegradient avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.