Migrate external commands to internal