Re-structured control file to commands

Used module.exports for each command and renamed file.