Skip to main content

All Questions

0 votes
0 answers
92 views

Windows: Remove file type from path completion

I've got an issue with my cmd environmental variables autocompletion (with TAB). For some reason, I'm getting suggestions for .dll .png and all other nonsense I don't care about. How do I exclude ...
Peter's user avatar
  • 101
8 votes
7 answers
28k views

WMIC output property value without property name

I'm entering something like that Desktop>wmic environment where(name="PATH" and systemVariable=FALSE) get variableValue VariableValue xxx But I don't want VariableValue to get into output. I want ...
Paweł Audionysos's user avatar
4 votes
2 answers
9k views

Write multi-line variable to .txt (CMD, NO .bat)

I'm successfully splitting %PATH% into multiple lines like this set t=%PATH:;=^&echo.% then this displays each path in new line nicely, just as I want: echo %t% However when I want to write ...
Paweł Audionysos's user avatar
0 votes
2 answers
1k views

Directory path in environment variable as argument to CMD command DIR

How can a Windows/CMD environment variable be used as argument to CMD's builtin dir command? >echo %pythonpath% C:\Program Files\Python35\Scripts\ >dir %pythonpath% The system cannot find the ...
handle's user avatar
  • 287
2 votes
1 answer
3k views

Does Windows7(+) have the env or equivalent? (Env. variable for single run of application) [duplicate]

I'm looking for an opportunity to launch an application (eg, compilers) with specific environment variables . I want same functionality like env in Linux. env var=value application.exe I found ...
Red Skotina's user avatar
6 votes
3 answers
14k views

Using setx to append to user PATH

My attempt: setx PATH "%PATH%;%~dp0" How do I do this without everything in system PATH getting duplicated in user PATH?
J.Doe's user avatar
  • 75
1 vote
1 answer
2k views

Git bash and cmd don't load my user account PATH variable

Start up a gitbash or a windows cmd session and run echo $PATH or echo %PATH% They both print the contents of the system PATH variable, but neither prints the contents of the PATH variable ...
chtenb's user avatar
  • 1,905
0 votes
1 answer
130 views

CMD doesn't update environment variables

When I edit the system environment variable PATH (or any other, I imagine) through Control Panel\System and Security\System > Advanced system settings, it doesn't update in CMD, even after ...
H.v.M.'s user avatar
  • 557
3 votes
2 answers
10k views

What is the default value of the PATHEXT environment variable for Windows?

What is the default value for the PATHEXT environment variable for different versions of Windows? Or even better: How can you reliably determine the original default system value for PATHEXT on a ...
ebpa's user avatar
  • 245
1 vote
3 answers
6k views

What does hyphen mean in Windows batch file?

In particular, I have problems understanding the hyphens in the following lines, which are from wikibooks if not -%1-==-- echo Argument one provided if -%1-==-- echo Argument one not provided & ...
midnite's user avatar
  • 571
0 votes
2 answers
3k views

'sample.exe' not recognised as internal or external command, operable program or batch file

Under Environment Variables, I set the path to sample.exe. I appended the System variable PATH with, C:\Program Files(x86)\Sample The sample.exe is in the Sample folder. Still, I get the above ...
MadhuraShree V N's user avatar
1 vote
2 answers
2k views

Is there an equivalent to source which allows me to have a batch script alter environment variables of the parent bash process?

My situation is this: I use python with conda on a windows machine, and work mostly in cygwin when on the command line. Now conda allows for different python environments, similar to virtualenv, but ...
kutschkem's user avatar
  • 194
2 votes
1 answer
579 views

Evaluate %PATH% as the system-scope environment variable exclusively

In Windows' command line, echo %PATH% appears to merge the system and the user variables PATH in such order before printing. That seems reasonable, but I would also like to be able to print only the ...
rhino's user avatar
  • 123
2 votes
2 answers
781 views

Why does the set command display more environment variables than the environment variables gui?

When I run the set command in command prompt the first variable I see is But when I open my Environment Variables GUI I don't see ALLUSERSPROFILE Why is that? There are numerous other variables ...
David says Reinstate Monica's user avatar
1 vote
1 answer
4k views

How to call environment variables in runas command for right click context menu

I am having trouble with using environmental variables with using runas when using the command in the registry for a right click context menu command. I have tried different methods of escaping the ...
ClearBlueSky85's user avatar

15 30 50 per page