Rewrite newpart command to allow console use