Here is a patch to _retreive_mac_apps. On 2005/05/12, at 1:27, Motoi Washida wrote:
Hi Ryan,I want to try your great patch, but I have one remote Tiger machine, which has not finished indexing. :(On 2005/05/12, at 0:42, lists wrote:After poking around some more, I think the best thing to do would be to modify _retrieve_mac_apps() so that it uses Spotlight to find the apps if you're running Tiger, and the old way if you're not running Tiger. This way the apps would be found using Spotlight the first time, then added to the cache so you don't have to keep using mdfind every time you try to tab complete an app's name. Motoi, since you are the expert on _retrieve_mac_apps() what do you think?I was just thinking about modifying _retrieve_mac_apps() to use Bill and Wataru's idea. If you don't mind, I'll modify and commit it.-Ryan On May 11, 2005, at 9:49 AM, lists wrote:I've done some tweaking based on the submission in <http://www.zsh.org/mla/users/2005/msg00479.html> (thanks Scott and Wataru) and have put together a patch for _mac_applications which uses the _tiger_mac_applications function from the aforementioned submission (which I've renamed to _spotlight_mac_apps since Spotlight will probably be around after Tiger). _mac_applications will now use Spotlight (via _spotlight_mac_apps) if you're running Mac OS X 10.4, and will fall back to the old way if you're not. I'm also including the modified _spotlight_mac_apps function (which will now check for an Applications folder in your home directory as well). Please let me know if there are any problems/objections.Thanks, Ryan <_mac_applications.diff.gz> <_spotlight_mac_apps.gz>-- Motoi Washida
-- Motoi Washida
Attachment:
_retrieve_mac_apps.patch.gz
Description: GNU Zip compressed data