Bulk of command implementation