Make sure Node.js 18 or later has been installed, and environment variables have been configured.
The default decompression path for ohpm is as follows: <DevEco Studio installation directory>\tools\ohpm or <command line tools installation directory>/command-line-tools/ohpm.
Symptom 1
After ohpm is installed on Windows, the ohpm commands do not work in the CLI.
Solution 1


Symptom 2
After ohpm is installed on Linux or macOS, the ohpm commands do not work in the CLI.
Solution 2
In the configuration file, add the path to the bin folder in the ohpm directory to the PATH environment variable. The following uses the macOS Zsh command line tool as an example.
vi ~/.zshrc
export PATH="/home/tctAdmin/ohpm/bin:$PATH"
source ~/.zshrc
ohpm -v
