sirdavidoff Posted March 8, 2018 Share Posted March 8, 2018 (edited) I find the 'Recent Places' list (in the drop-down menu of save dialogs) very useful. However, I'd like to extend it to include directories I've recently opened with Alfred. To do so I need to know which directories Alfred has opened. Is there either: 1) An 'on directory open' hook in Alfred that I could tap into, or 2) A list of directories recently opened by Alfred somewhere that I can read? Please note I only want directories opened with Alfred, not ones opened by double-clicking in the Finder. Edited March 8, 2018 by sirdavidoff Link to comment
deanishe Posted March 8, 2018 Share Posted March 8, 2018 48 minutes ago, sirdavidoff said: Is there either No and no. Depending on how you open folders with Alfred, you might be able to make your own list with a workflow (for example, I almost always use a Filter Filter with keyword f for folder search, so I could easily add an additional element to save the path). But even assuming that's viable for you, how are you going to get the directory paths out of your list and into the Recent Places list? You can't just add them to ~/Library/Preferences/.GlobalPreferences.plist. That doesn't work. Link to comment
sirdavidoff Posted March 9, 2018 Author Share Posted March 9, 2018 (edited) Ah, but you can edit the Recent Places list! defaults write -g NSNavRecentPlaces = '("/test","/test2","/test3")' However, it seems that even a file filter wouldn't work if I then navigate the filesystem with the arrow keys in Alfred, which I do quite a lot Edited March 9, 2018 by sirdavidoff Link to comment
deanishe Posted March 9, 2018 Share Posted March 9, 2018 29 minutes ago, sirdavidoff said: Ah, but you can edit the Recent Places list! But it doesn't change what the Save dialog actually shows… Link to comment
sirdavidoff Posted March 9, 2018 Author Share Posted March 9, 2018 (edited) Does for me... (on 10.11.6) Edited March 9, 2018 by sirdavidoff Link to comment
deanishe Posted March 9, 2018 Share Posted March 9, 2018 Newly-started apps pick up on the changes. Already running ones don't. Link to comment
sirdavidoff Posted March 9, 2018 Author Share Posted March 9, 2018 Already-running apps also work for me. However I suspect we may be talking about different things. I mean the list you get on clicking on the drop-down menu at the top of an open/save dialog box. Perhaps you mean a different list? Link to comment
deanishe Posted March 9, 2018 Share Posted March 9, 2018 No, I mean exactly the same thing. On my system, changes to NSNavRecentPlaces from a terminal are not seen by running apps, which is exactly the behaviour I would expect to see, as you're always told to quit running apps before messing with their settings, or the changes won't be noticed. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now