Click here to Skip to main content
15,845,436 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have an executable file docker.exe under C:\Program Files\Docker Toolbox.

I did set the environment variable PATH and it includes the folder. However when I run the command under ps. It can't find it. Please tell me the details to fix it permanently.

What I have tried:

PS C:\Users\me> docker
docker : The term 'docker' is not recognized as the name
Check the spelling of the name, or if a path was include
At line:1 char:1
+ docker
+ ~~~~~~
+ CategoryInfo : ObjectNotFound: (docker:St
+ FullyQualifiedErrorId : CommandNotFoundException

PS C:\Users\me> docker
docker : The term 'docker' is not recognized as the name
Check the spelling of the name, or if a path was include
At line:1 char:1
+ docker
+ ~~~~~~
+ CategoryInfo : ObjectNotFound: (docker:St
+ FullyQualifiedErrorId : CommandNotFoundException
Posted
Updated 18-Mar-16 6:51am
Comments
RedDk 18-Mar-16 13:04pm    
I'm no powershell expert and do occasionally run MSDOS batches but scripting is not my thing. Basic computer however dictates might apply to powershell; I'm interested to hear what you have to say about dragging a commandline console into "Program Files" and typing in "dir /x", however.

'Guess I'll volunteer.

Replace "Program Files" with whatever "dir /x" shows as cooresponding to it in the powershell script?

1 solution

This SO post should give you a clue:
SO: Setting Windows PowerShell path variable[^]
 
Share this answer
 
Comments
[no name] 18-Mar-16 12:11pm    
I read it but I don't understand it. I right click my computer then select property. Then Advanced system setting=>Environment Variables=>Click PATH. But doing what?
phil.o 18-Mar-16 12:31pm    
I'm surprised because the link I provided does not talk at all about right clicking the computer and change the PATH variable.
On the other hand, there are several explanations about how to use/change this environment variable under PowerShell, and the drawbacks that you can encounter while you try (for example, PowerShell does not like the double quotes enclosing paths - these double-quotes have to be removed).
[no name] 18-Mar-16 13:20pm    
I mean can I manually to edit the PATH variable to make calling docker in PS working? My PATH variable doesn't have double-quotes. I am not strong on PS.

C:\Users\me\.dnx\runtimes\dnx-clr-win-x86.1.0.0-rc1-update1\bin;C:\Users\me\.dnx\bin;C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Program Files (x86)\Common Files\Microsoft Shared\Windows Live;c:\Program Files (x86)\AMD APP\bin\x86_64;c:\Program Files (x86)\AMD APP\bin\x86;C:\Program Files (x86)\Intel\iCLS Client\;C:\Program Files\Intel\iCLS Client\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;c:\Program Files (x86)\ATI Technologies\ATI.ACE\Core-Static;C:\Program Files (x86)\Windows Live\Shared;C:\Program Files\Dell\Dell Data Protection\TSS\bin\;C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit\;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files (x86)\Skype\Phone\;C:\Program Files\Microsoft DNX;C:\Program Files\Docker Toolbox;C:\Users\me\AppData\Roaming\Dashlane\4.1.0.99957\bin\Firefox_Extension\{442718d9-475e-452a-b3e1-fb1ee16b8e9f}\components

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900