Looking at the code, TextMate appears to start with a list taken from “Find in Folder Globs.default”, which doesn’t exist, so it falls back to hard-coded defaults.
I find myself adding the same patterns to almost every project so I’d like to change the defaults.
Is there a way to set that via `.tm_properties` or do I just have to add a key named “default” to `com.macromates.TextMate.plist` manually?
Thanks.
What is your goal with changing the default? Could it be accomplished with excludeInFileChooser, excludeInBrowser, and/or excludeInFolderSearch?
Ref: http://textmate.1073791.n5.nabble.com/TM2-Excluding-directories-from-searche...
Thanks,
Graham
On July 28, 2017 at 8:31:14 AM, Rob McBroom (mailinglist0@skurfer.com) wrote:
Looking at the code, TextMate appears to start with a list taken from “Find in Folder Globs.default”, which doesn’t exist, so it falls back to hard-coded defaults.
I find myself adding the same patterns to almost every project so I’d like to change the defaults.
Is there a way to set that via .tm_properties or do I just have to add a key named “default” to com.macromates.TextMate.plist manually?
Thanks.
-- Rob McBroom http://www.skurfer.com/
_______________________________________________ textmate mailing list textmate@lists.macromates.com http://lists.macromates.com/listinfo/textmate
On 2 Aug 2017, at 10:32, Graham Heath wrote:
What is your goal with changing the default? Could it be accomplished with excludeInFileChooser, excludeInBrowser, and/or excludeInFolderSearch?
I know about those and use them regularly.
I’m talking about the list of extensions that appears next to “matching” in the Find/Replace window. By default, it includes `*`, `*.txt`, and `*.{c,h}`.
It would be nice if I could have every new project include other things by default, like `*.py` or `*.html` since I always end up adding them anyway.
On Fri, Jul 28, 2017 at 9:30 AM, Rob McBroom mailinglist0@skurfer.com wrote:
Looking at the code, TextMate appears to start with a list taken from “Find in Folder Globs.default”, which doesn’t exist, so it falls back to hard-coded defaults.
I find myself adding the same patterns to almost every project so I’d like to change the defaults.
Is there a way to set that via .tm_properties or do I just have to add a key named “default” to com.macromates.TextMate.plist manually?
No, the default values cannot be changed. But since `OakHistoryList` stores the values (per project) in the plist, so it makes sense to me to have it store "defaults" values there too such that you can set them via:
defaults write com.macromates.TextMate "Find in Folder Globs" -dict-add default '("*", "*.py", "*.html")'
I think that should be a straight forward change, if you're interested in submitting a PR.
Ron
Thanks.
-- Rob McBroom http://www.skurfer.com/
textmate mailing list textmate@lists.macromates.com http://lists.macromates.com/listinfo/textmate
On 2 Aug 2017, at 12:12, Ronald Wampler wrote:
No, the default values cannot be changed. But since `OakHistoryList` stores the values (per project) in the plist, so it makes sense to me to have it store "defaults" values there too such that you can set them via:
defaults write com.macromates.TextMate "Find in Folder Globs" -dict-add default '("*", "*.py", "*.html")'
I believe you can already do that.
https://github.com/textmate/textmate/blob/master/Frameworks/Find/src/FindWin...
I initially asked if I just needed to add the data to the prefs manually. It sounds like the answer is “yes”.
Thanks!