hardhat
hardhat copied to clipboard
hh shorthand opens HTML help on windows
If you use the hh
shorthand cli tool on Windows, it opens the HTML help app:
Initially raised in this discussion: https://github.com/NomicFoundation/hardhat/discussions/4971
Reproduction steps
- Install the
hh
shorthand based on the setup instructions of the Hardhat guide:npm install --global hardhat-shorthand
- In a Hardhat project run
hh compile
orhh test
- The HTML Help app will be inexplicable opened
Hi, this is not really a bug.
The reason why you type hh
some strange web come up, is that hh
in windows is point to C:\Windows\hh.exe
.
C:\Windows\hh.exe
is the executable file for the helper program (HTML Helper) in Windows. When you open a Help file (usually a file ending with a .chm extension) on Windows, hh.exe is used to open and display the Help content.
So it is conflict with hh
of hardhat-shorthand.
How to solve this
- Install hardhat hh through
npm install --global hardhat-shorthand
, and find it withnpm list -g --depth 0
. - And change the name
hh/hh.cmd
toht/ht.cmd(any name you like)
, or change the hh.exe of windows to other name. - Use the name [
ht/ht.cmd
with step 2 ].
Hope this answer will help you.