DEV Community

Shiono Yoshihide
Shiono Yoshihide

Posted on

Tiny Pro Tips for Windows

Hi, today I'll show you my favorite tiny tips for Windows.

Usually we use "right click" and see some context menu like this:

context menu

This right click context menu is editable by regedit.exe.

At this time I'll recommend some tips I use so many times.

CMD.EXE HERE

Do you wanna open cmd.exe and change directory HERE? I do!!

cmd-here1

cmd-here2

Here is the two source code:

(directory and directory background)

directory

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\directory\shell\cmd-here]
@="CMD.EXE HERE"
"Icon"="cmd.exe"

[HKEY_CLASSES_ROOT\directory\shell\cmd-here\command]
@="cmd.exe /K \"cd /d %1\""
Enter fullscreen mode Exit fullscreen mode

directory background

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\directory\background\shell\cmd-here]
@="CMD.EXE HERE"
"Icon"="cmd.exe"

[HKEY_CLASSES_ROOT\directory\background\shell\cmd-here\command]
@="cmd.exe /K \"cd /d %v\""
Enter fullscreen mode Exit fullscreen mode

Just open cmd.exe and cd %1(or %v argument), easy enough?

To install it, you can download any *.reg file from this repository:

https://github.com/saltyshiomix/tiny-pro-tips-for-windows

COPY PATH

Next, "COPY PATH" context menu.

copy-path

Here is the three source code:

(file, directory and directory background)

file

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\*\shell\copy-path]
@="COPY PATH"

[HKEY_CLASSES_ROOT\*\shell\copy-path\command]
@="cmd.exe /c \"(echo.|set /p=\"%1\")|clip\""
Enter fullscreen mode Exit fullscreen mode

directory

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\directory\shell\copy-path]
@="COPY PATH"

[HKEY_CLASSES_ROOT\directory\shell\copy-path\command]
@="cmd.exe /c \"(echo.|set /p=\"%1\")|clip\""
Enter fullscreen mode Exit fullscreen mode

directory background

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\directory\background\shell\copy-path]
@="COPY PATH"

[HKEY_CLASSES_ROOT\directory\background\shell\copy-path\command]
@="cmd.exe /c \"(echo.|set /p=\"%v\")|clip\""
Enter fullscreen mode Exit fullscreen mode

Conclusion

"CMD.EXE HERE" and "COPY PATH" are so useful when you develop on Windows machine.

I'm very happy if you use these useful tips :)

Thank you for your reading my article!

GitHub logo saltyshiomix / tiny-pro-tips-for-windows

Tiny but pro tips for Windows






Top comments (8)

Collapse
 
djquecke profile image
DJ Quecke

Perfect timing. I just put together a new computer and I've missed the CMD Prompt feature I had installed on my last machine. I meant to go looking for it and it came to me....Thanks Much

Collapse
 
andy profile image
Andy Zhao (he/him)

Awesome, great tips! Definitely going to play with editing regedit.exe.

Collapse
 
saltyshiomix profile image
Shiono Yoshihide

Thanks Andy!
And you can customize any registered executables! :)

Collapse
 
jess profile image
Jess Lee

Hey Shiono! Just wanted to share that you can embed github repos with this syntax:

{% github https://github.com/saltyshiomix/tiny-pro-tips-for-windows %}

Collapse
 
saltyshiomix profile image
Shiono Yoshihide

Thank you for letting me know!
I'ts so nice to use, I remember it :)

Collapse
 
chiff profile image
Chiffre

that cmdExeHere is not needed :) just go to explorer -> open folder where you want your cmd -> go to navigation of cmd -> type cmd

Collapse
 
saltyshiomix profile image
Shiono Yoshihide

Oh I don't know that!!
Thank you for letting me know :)

(But may be legacy Windows like Win7, that navigation is not supported, yet)

Collapse
 
pkristiancz profile image
Patrik Kristian

I year use my tuned version of Total Commander and theese functions are implemented there as well :)