I'm able to install a custom plugin globally via npm i -g @somescope/myplugin then change into the directory where the package is globally installed and can run sfdx plugins:link and all my custom commands are available.

However, I'm not able to use it when installing it from an internal private registry via sfdx plugins:install @somescope/myplugin.

Other custom plugins out on the public GitHub seem to work with doing a global npm install without a link step. See mo-dx, shane-sfdx-plugins, and many others.

What does the sfdx install approach do underneath to associate the plugin with DX that doesn't happen when doing a global npm install?


There is a known issue logged for this on the repo here

You can workaround for now by using the GitHub URL and using below

sfdx plugins:install https://github.com/someuser/someplugin

I am assuming you have a private git repo

  • 2
    Thank you Mohith, yes I have a private repo, was not aware there was a known issue. Much appreciated. – trebleCode Nov 20 '20 at 17:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.