VSCODEのSalesforceのCLIを更新の場合(SFDC(V7)からSF(V2)へ更新)、タイトルのエラーメッセージを表示しました。
対応策は以下です。
①
Uninstall Salesforce CLI or Plugins
②
削除ファイル
C:\Users\「自分のユーザ」\AppData\Local
C:\Program Files
上記フォルダの「SFDX」と「SF」を全部削除してください。
③
更新手順
英語
⑴
Remove/Uninstall all Salesforce CLIs.
Remove all the traces like removing the Path entry in System Settings.
Check the status by running sfdx and sf commands.
⑵
Then follow the installtion with npm as described in this link
Move from sfdx (v7) to sf (v2).
The main commands are
1) npm uninstall sfdx-cli --global
2) npm install @salesforce/cli --global.
Now both sf and sfdx commands will work as sfdx is now aliased to sf.
You can verify this by running sf version and sfdx version. Both will return same result.
リンク: