Jump to content

Go To Here


Recommended Posts

Very useful workflow!

 

Is it possible to add this feature:

If there are no open/save dialogs open, make the directory open in Finder instead. I think one of the scripts here has similar functionality (this, plus the opening in Finder instead if no open/save dialogs are out). The script in question is Carlos-Sz's Recent Items workflow (http://www.alfredforum.com/topic/713-recent-items-40-docs-folders-apps-custom-categories-favorites-interaction-with-opensave-dialogs-and-more/), and the functionality is in "alt" modifier of the "fav" script filter. 

 

Hi

 

I'm not expert in AppleScript, but you can go ask Alfred to open any folder if no open/save dialogs is available

 

 

In Alfred window just type

'Folder_Name

then hit enter and it will open the folder in Finder

Link to comment
  • 1 year later...

I'm a QS -> Alfred immigrant, too.  I love QS, but having to learn ObjC in order to add modules is a show stopper to me.

 

Love this workflow, ahmadt.  Thanks for having created it.

 

Quick question, but can you invoke a File Action with a keyboard shortcut?  Say I've got a save dialog open in Atom, and I browse for a directory in Alfred, can I configure it so that when the selected directory is show in Alfred, I can just hit something like Shift-Cmd-G to tell Alfred to run that File Action?

Link to comment
On 13/7/2015 at 7:26 PM, paulw said:

Fantastic! Really the only reason I have Default Folder X installed. Now I can just use this.

How do you stop using "Default Folder X"?. Could you explain how this works. Please. Thank you

Edited by 2pilvic
Link to comment
  • 9 months later...
  • 6 years later...
Posted (edited)

just for fun @paulw, I thought I would try and recreate this without the applescript but with alfred's built in objects.

 

image.thumb.png.cdfb3f5b53469037e1fce7624b53e388.png

 

And just another thought -- if you wanted to recreate some of the functionality of default folder x, you could also created a list filter with favorite folder paths as well.

Edited by sepulchra
additional comment
Link to comment
Posted (edited)

@sepulchra It's just a matter of minor convenience, to save the extra step of accessing clipboard history, in case the current clipboard was needed for something. For example, opening a file to paste the current clipboard contents into. I had thought that making the path transient would remove it from the current clipboard after pasting and restore the previous clipboard, but it doesn't. Perhaps there a more optimized way of accomplishing what I'm going for, though?

 

Added a file filter as you suggested, that works great.

 

I also added a small applescript based on the original workflow to check whether the frontmost application has a dialog window, and only continue if one exists. I wonder if there's a way to detect specifically if the dialog window is Open/Save?

 

Here's the layout of the new workflow:

 

image.thumb.png.51836650047267b6025b8250ae21f047.png

 

 If you or others don't have further suggestions, I'll update the repo to this one, or incorporate new suggestions. Thanks for your help!

Edited by paulw
Link to comment
Posted (edited)

very cool. I was asking about the clipboard usage because I think you can accomplish what you are looking to do by just marking the first "copy to clipboard" object that pastes the variable as transient. It is a checkbox at the bottom. this way you don't need to have the additional clipboard variable and copy to clipboard ... i think? if i am understanding your usage.. It does not end up in my clipboard history that way.

 

 

EDIT: deleted my second question as I answered it.

Edited by sepulchra
Link to comment

just adding another note as my coffee is just kicking in..... if you are using a file filter and if I'm understanding your flow, do you need the file action? If you are going to search for a folder at the outset? Or do you find yourself identifying the folder in the finder first? I like the idea of the file filter and setting the date range in limit and sort to "today" or "Last 3 Days"

 

you could also add a List Filter if you had a fixed set of favorites you want to have access to all of the time.

Link to comment

Marking as transient makes the entry not appear in Clipboard History, but it is still in the clipboard at that moment. Meaning that if you ⌘V, that’s still what you’ll get.

 

There may be a simpler way to accomplish this, but I’ll take a look when the next version of the workflow is released.

 

As for File/Universal Action VS File Filter, my recommendation is having both. They don’t really trample on each other and different people have different mental models. I, for example, always use File/Universal Actions because I tend to find the file first (could be in Finder but equally as likely it’s in Alfred via the Thumbnail Navigation’s Fast Entries feature or a simple search). But I often add File Filters if they make sense (and I don’t forget) for other people.

 

9 hours ago, paulw said:

I wonder if there's a way to detect specifically if the dialog window is Open/Save?

 

Unsure. I’ll look at it when the new version is live and report back if I come up with something.

Link to comment

@sepulchra, @vitor explained the need for restoring the previous clipboard item well. I figure doing it the way I did, rather than accessing clipboard history with {clipboard:2}, makes the workflow still work even if a user has Alfred's clipboard history turned off.

 

Thanks for the idea about the list filter. Adding it as an option. Is there a way to use the workflow itself to add (or subtract) entries from the List filter?

 

2 hours ago, vitor said:

Unsure. I’ll look at it when the new version is live and report back if I come up with something.

 

Great, thanks!

 

Updated the workflow: https://github.com/paulrudy/alfred-go-to-here/releases/tag/v2.0.1

Link to comment
12 minutes ago, paulw said:

Is there a way to use the workflow itself to add (or subtract) entries from the List filter?

 

If the list needs to be updated dynamically, that’s more the job of a Script Filter. Do keep in mind that if you add a Filter (List, Script, or File) in this workflow with your preferred locations, it’s no long generically shareable to other people (which is OK). You could e.g. have another workflow with your specific Filter, and then have it call this workflow via an External Trigger. Best of both worlds: It works for you without extra steps and is shareable to other people.

 

Haven’t inspected the current version yet, will do that later.

 

Have a nice weekend.

Link to comment
9 hours ago, vitor said:

If the list needs to be updated dynamically, that’s more the job of a Script Filter.

I have workflows with script filters, but I haven't actually implemented one before. Would the dynamic updating be done by creating a script for the Script Filter that updates a json file in the workflow folder with new or edited entries? By any chance could you point me to an example workflow where something similar is being done?

Link to comment
13 hours ago, paulw said:

@sepulchra, @vitor explained the need for restoring the previous clipboard item well. I figure doing it the way I did, rather than accessing clipboard history with {clipboard:2}, makes the workflow still work even if a user has Alfred's clipboard history turned off.

 

Thanks for the idea about the list filter. Adding it as an option. Is there a way to use the workflow itself to add (or subtract) entries from the List filter?

 

 

Great, thanks!

 

Updated the workflow: https://github.com/paulrudy/alfred-go-to-here/releases/tag/v2.0.1

Go to here shortcut working for MS excel, word etc in open dialog but not in save. Is opt + command + G valid shortcut in save dialog as it does work for me? I checked for conflicting keyboard shortcut shortcut on my machine using Aalpha workflow. Request you to please check this 

Link to comment
3 hours ago, TomBenz said:

Is opt + command + G valid shortcut in save dialog

 

Perhaps just a typo, but it's shift+cmd+G, and yep, that one is a valid shortcut.

(Btw. it's the same for Finder windows, i.e. the shortcut is for a generic "Go to Folder" utility.)

Link to comment

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...