Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

TextMate won't find files in project folder

This was working before, but now whenever I use TextMate to find matches across all files in my project folder, it says searched 0 files.

Has anyone had this happen to them and what did you do to fix it?

like image 727
kevinkt Avatar asked Dec 19 '25 05:12

kevinkt


1 Answers

Yes, this has happened to me. I've been able to fix it in an number of ways.

Starting from the beginning;

[Edit -> Find -> Find in Project] or [Command + Shift + F] is how you open the Find window with your project preselected.

This should produce a window similar to this;

Find in project window with project below

Some important fields;

  • "In: " is set to your project folder.
  • "Regular Expression" is unchecked.
  • "Matching" is set to *. This will search every file

Any of these could cause unexpectedly empty searches.

However, this is pretty much day to day stuff, so once you've checked this there's a few more things to look at.

TextMate will look in a few places for Find Window includes and excludes, so check in ~/.tm_properties and [Your Project]/.tm_properties for these excludes;

  • exclude
  • excludeFiles
  • excludeDirectories
  • excludeInBrowser
  • excludeInFolderSearch
  • excludeInFileChooser
  • excludeFilesInBrowser
  • excludeDirectoriesInBrowser

From dvessel's tm_properties documentation

These are all globs and perhaps a bit arcane. (Note that the glob syntax is documented in the built-in help system.)

The file browser, if it has a file, checks that file against the first key with a value in this order: excludeFilesInBrowser, excludeInBrowser, excludeFiles, exclude. If neither match, it then does the same with include keys, and if one match, it is included.

The default include key is * (so no hidden files, although see the default .tm_properties which include .htaccess and .tm_properties). The default exclude key is the empty string (nothing matches).

The defaults for .tm_properties files are located here: TextMate.app/Contents/Resources/Default.tmProperties

If worse comes to worse, you can reset TextMate to its defaults following this Stack thread

like image 85
Graham P Heath Avatar answered Dec 21 '25 04:12

Graham P Heath



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!