Keyboard shortcut for copy path to clipboard

Have a suggestion for "Everything"? Please post it here.
Post Reply
edanm
Posts: 6
Joined: Thu Apr 15, 2010 3:09 pm

Keyboard shortcut for copy path to clipboard

Post by edanm »

One of the ways I want to use Everything is to quickly get a path string to a file I want.
For example, if I want to upload a picture to a website, when the "File: Open" dialog comes up, I want to use Everything to find the file I want, and copy its path.

Right now, the only way I see to copy the file path is to:
right click on it
wait for windows to open the context menu (takes time!)
click "copy path to clipboard"


Having a shortcut to do this for me would go a long way towards making my life better :)

Thanks,
Edan
P.S. I'm very new to Everything. Am I missing some obvious way to do this which already exists?
cacamama
Posts: 40
Joined: Tue Apr 28, 2009 5:21 pm

Re: Keyboard shortcut for copy path to clipboard

Post by cacamama »

There's keyboard shortcuts, to copy the path and copy the full path&name, ctrl+alt+c and ctrl+shift+c respectively. There's also a keyboard shortcut tab in the options page where you can search for specific keyboard shortcuts.

Btw, I wrote a script that provides the exact functionality you asked for. But it never garnered any attention.
http://forum.voidtools.com/viewtopic.ph ... p=407#p407

The link is dead, I'll copy the source back to dropbox =)

Here's a screencast:
http://www.screentoaster.com/watch/stUk ... k_app_demo

Here's how it works, you type something, anywhere, and hit the hotkey, which will bring up the filename (actually there are two hotkeys, one pastes in the first result, kinda like google's i'm feeling lucky, and the other brings up a menu where your mouse pointer is and allows you to select the file). Dead simple. The source is available too, so no fishy business.
edanm
Posts: 6
Joined: Thu Apr 15, 2010 3:09 pm

Re: Keyboard shortcut for copy path to clipboard

Post by edanm »

Hmm, the shortcuts aren't working for me and I *don't* see any pane in the options for keyboard shortcuts.
Is it in a beta release or something? I'm just using the (win installer) version I got from the main site.


As for your plugin, it looks great.
Although I think it would be better to just pop up the actual Everything window, then whatever you hit enter on there will be copied back.
(Is that what you wanted them to implement?)

Edan
cacamama
Posts: 40
Joined: Tue Apr 28, 2009 5:21 pm

Re: Keyboard shortcut for copy path to clipboard

Post by cacamama »

The shortcuts are mentioned are available in the latest beta:

http://www.voidtools.com/Everything-1.2.1.451a.zip
As for your plugin, it looks great.
Although I think it would be better to just pop up the actual Everything window, then whatever you hit enter on there will be copied back.
(Is that what you wanted them to implement?)
Sort of, but assigning the return key to send the location back to previous window is not convenient, as pressing enter opens the selected file/folder in "Everything". On the other hand, I could write a script that when activated (with the everything window active of course) would copy the path of the selected file/folder, minimize everything and send the copied path to the foreground window. Heck, I could make it so it uses the enter key, as long as I configure it so that it activates only when the active window is Everything, though you may run into problems with using the enter key.
edanm
Posts: 6
Joined: Thu Apr 15, 2010 3:09 pm

Re: Keyboard shortcut for copy path to clipboard

Post by edanm »

Awesome. It works!
Everything is now my new favorite application :)


Yeah I figured it would be difficult to make an AHK script which does what I suggested.
It would have to be a native ability of Everything.

I'd imagine a shortcut which pops up Everything like normal, except enter would send the full path back to whatever window was open last.
Hope they make such a feature some day.


Are you uploading your script to dropbox, btw? I'd like to check it out...

Edan
cacamama
Posts: 40
Joined: Tue Apr 28, 2009 5:21 pm

Re: Keyboard shortcut for copy path to clipboard

Post by cacamama »

The method you mentioned was actually easier to implement, and a little less crude compared to that of my previous script. Here's the code:

Code: Select all

#NoTrayIcon
#SingleInstance
#j::                          ; The keyboard shortcut
{
SetTitleMatchMode 2
      IfWinActive, Everything ; Runs only if Everything is the foreground window (If title of the active windows contains "Everything"
      {
        Send ^+c              ; Sends ctrl+alt+c to copy the full path, assuming the default shortcut is intact
        Send {ESC}            ; Close/minimize "Everything"
        Send ^v               ; Send the path to the foreground window
      }
return
}
And here's the executable if you're interested:
http://dl.dropbox.com/u/677762/everything%20thingie.exe

Note that I assigned Win+J to do the job, you have to change the source and either compile the script , or run it by installing Autohotkey.

I like this script better than it's previous version, give it a shot =)

Edit: Fixed a minor booboo, apparently the title of the Everything window changes when you type in letters
Last edited by cacamama on Thu Apr 15, 2010 5:54 pm, edited 1 time in total.
cacamama
Posts: 40
Joined: Tue Apr 28, 2009 5:21 pm

Re: Keyboard shortcut for copy path to clipboard

Post by cacamama »

My previous script is available at the Authotkey forums:
http://www.autohotkey.com/forum/topic41741.html

Try the one I posted above, it's a lot more streamlined and much less error prone (after all, it's only copying the path, closing the Everything window and pasting the path in whatever textbox is active, what could possibly go wrong?).
cacamama
Posts: 40
Joined: Tue Apr 28, 2009 5:21 pm

Re: Keyboard shortcut for copy path to clipboard

Post by cacamama »

It's also possible to assign a different shortcut to launch the script, make the script wait till you press enter, and then do what the above code does. I use win+q to launch "Everything", the script would fire up the Everything window when win+j is pressed, wait for you to press enter and then close Everything and paste the path to the foreground window.

It'd be a little less stable though, I'll try and see how it works.
edanm
Posts: 6
Joined: Thu Apr 15, 2010 3:09 pm

Re: Keyboard shortcut for copy path to clipboard

Post by edanm »

I tried it, works great.

Probably good enough that the other functionality (waiting for the enter) is not too necessary.
cacamama
Posts: 40
Joined: Tue Apr 28, 2009 5:21 pm

Re: Keyboard shortcut for copy path to clipboard

Post by cacamama »

Glad you like it, I'm going to use it myself. I don't get why no one showed any interested in such a functionality, it's pretty useful imho. Anyway, I'll work on the other script, but Autohotkey's acting up.
ChentongTian
Posts: 1
Joined: Tue Mar 09, 2021 1:21 am

Re: Keyboard shortcut for copy path to clipboard

Post by ChentongTian »

Need this shortcut too!


at least 30 times per day I copied the path, pasted it into the file explorer's address field, so it will be the destination of downloaded files
void
Developer
Posts: 16739
Joined: Fri Oct 16, 2009 11:31 pm

Re: Keyboard shortcut for copy path to clipboard

Post by void »

To create a keyboard shortcut to copy the part part of the select item:
  • In Everything, from the Tools menu, click Options.
  • Click the Keyboard tab on the left.
  • In the command list, Select File | Copy Path to Clipboard
  • Click Add....
  • Press Alt + C (or some other keyboard shortcut)
  • Click OK.
  • Click OK.
Post Reply