A secret of right-clicking "Open command line window here"
A secret of right-clicking "Open command line window here"
As we all know, Windows 7 provides a shortcut to enable the cmd command line window from the current folder:
Shift + right-click => "Open the command line window here"
In this way, you can quickly open the cmd window in the current directory to execute commands.
Today, when configuring the ant environment variable, add the ant bin directory to the path variable, use the preceding method to open the directory of the project to be built, and enter the ant command, always Prompt:
'Ant' is not an internal or external command, or a program or batch file that can be run.
This is strange. The name adds the ant bin directory to the path.
Next, try WIN + R, Enter cmd, press enter, open the cmd window, cd to the directory to be built, and execute ant.
The three views are ruined, and no reasonable explanation is provided after Google duniang's help.
For a cainiao programmer, restarting is the final trick. I leave a hand, just unregister it, and try again. It is OK.
That is to say, there is a problem in the cmd window opened in this mode: If a configuration in the environment variable is modified, the cmd window opened in this mode cannot obtain the updated configuration, you can read the new configuration only after logging out of the operating system and logging on again. This problem does not occur when you open the cmd window in the traditional way.
I wrote this little bug in a rush. If you have any students, it will save you a waste of time.