jiafu
jiafu

Reputation: 6556

'gpg.exe' is not recognized as an internal or external command after setting environment?

[INFO] --- maven-gpg-plugin:1.4:sign (sign-artifacts) @ server-test-toolkit --- 'gpg.exe' is not recognized as an internal or external command,

I have set the environment path:

%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\;C:\MinGW\msys-7.2\bin;C:\Program Files (x86)\GNU\GnuPG

I run the gpg in cmd.exe in windows, it is OK.

But when running the maven-gpg-plugin in eclipse why still popup the error: 'gpg.exe' is not recognized as an internal or external command,

Upvotes: 4

Views: 8383

Answers (2)

Nahush
Nahush

Reputation: 541

when you receive this error message, “gpg is not recognized as an internal or external command” then you need to update your PATH variable.

To do this without reboot:

  1. Open up a command prompt window
  2. Paste this in:

    SET PATH=%PATH%;C:\Program Files (x86)\GNU\GnuPG
    
  3. Hit Enter

Upvotes: 0

Julien
Julien

Reputation: 1312

Rebooting solved the issue.

I guess the Maven runtinme didn't had his path updated after the GPG installation. Logging off and relogging may also be sufficient.

Upvotes: 4

Related Questions