Command worked for me except for an M1 MacBook Pro running macOS 12.5 I
had to execute that command AFTER going through Setup Assistant. Then I
used the System Preference option to "Erase all Content and Settings"
and then went through Setup Assistan...