2017-05-30 43 views

回答

5

對於下面的指南,我們要添加一個名爲mytool.exe的實例工具,它位於C:\Users\NewFolderInPath\mytool.exe中,以便每次我想要執行mytool實用程序時,我都不必指定完整路徑。

我以此爲例,您可以用更實際的東西替換文件夾,如位於此處的JDK bin目錄C:\Program Files\Java\{JDK_VERSION}\bin以執行javackeytool或您想要的任何東西。

步驟1 - 點擊Windows圖標

enter image description here

步驟2 - 點擊Settings圖標

enter image description here

步驟3 - 點擊System

enter image description here

步驟4 - 點擊About

enter image description here

步驟5 - 點擊System info

enter image description here

步驟6 - 點擊Advanced system settings

enter image description here

步驟7 - 點擊Environment variables...

enter image description here

步驟8 - 選擇Path行,然後單擊Edit

enter image description here

步驟9 - 點擊New,然後單擊Browse,然後在接下來的面板將打開你需要選擇你的Path所需的文件夾。對於本指南的首要前提,我將添加的文件夾C:\Users\NewFolderInPath

enter image description here

步驟10 - 點擊OK,點擊每一個OK按鈕,你會遇到封閉每個以前的Windows。

enter image description here

步驟11 - 打開一個command prompt (cmd),現在你可以在不指定完整路徑執行你的工具。

enter image description here

注:對於每一個問題,在下面留言,我會盡快我可以回答。 祝你好運和快樂編碼:)

+0

除此之外演練這段視頻是有幫助的 - https://www.youtube.com/watch?v=extCL1UU5wk,所以是這個https://www.youtube。 com/watch?v = gBHOeI5QB8M瞭解什麼測試命令可以嘗試,並且它不會工作,直到您關閉命令提示符並重新打開它(看起來像我現在有keytool正在運行:) – NukeouT