Added status and refactored
Switched to getopt for switch parsing
Refined action parsing