function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Prakash Rai 7Prakash Rai 7 

Trailhead Quick Start:Unlocked Packages

Unable to create a package version. Since I have PG2 enabled, I tweaked the command than on the trailhead and I get the error below. Any help?

GIFter git:(master) ✗ sfdx force:package2:version:create -i 0HoxxxxxxxxxxxxCAC
ERROR:  The --package2id (-i) value [0HoxxxxxxxxxxxxCAC], doesn’t match the id value in any packageDirectories specified in sfdx-project.json.
Prakash Rai 7Prakash Rai 7
This is interesting. I have sfdx-cli version sfdx-cli/6.49.0-8edc6e0f5d (darwin-x64) node-v8.9.4 both on Mac and PC.  package command works OK on PC and I was able to create package and version. Mac suggestes to use package2 and errors to create package2.

➜  dreamhouse-sfdx git:(master) ✗ sfdx force:package:list
 ▸    force:package:list is not a sfdx command.
 ▸    Perhaps you meant force:package2:list
 ▸    Run sfdx help force for a list of available topics.

Any suggestion with package command behaves differently in Mac and PC?
Prakash Rai 7Prakash Rai 7
Happens to be my salesforcedx plugin was behind on Mac. Uninstalling the plugin and updating the sfdx solved the issue.