3

Possible Duplicate:
What is the equivalent of Linux's “~” in Windows?

For example, is there a character I can enter in place of the asterisk in the string "*\Videos" that is equivalent to typing the string "C:\Users\myusername\Videos"?

I'm particularly interested in using this method to jump to my user directory from the Windows key dialog.

Please pardon any butchering of technical terminology.

0

1 Answer 1

6

Unfortunately, in regular windows prompt there is no shorthand notation. You can use %userprofile% or %homepath%, for example cd %userprofile% and cd %HOMEPATH%\Videos as per your example

In Powershell, however, you can use the tilde ~. If you use console a lot I would recommend creating a shortcut to the Powershell rather than regular command prompt

2
  • 1
    Yep: I wrote home.bat for myself, it looks like this - @cd /d %userprofile%. So I don't type it at, I just run "home".
    – Mark Allen
    Sep 17, 2012 at 18:36
  • You can create your own environment variables to accomplish something like ./, but you have to use the %variable% notation (e.g. %./%) Sep 17, 2012 at 18:40

Not the answer you're looking for? Browse other questions tagged .