added the add command functionality.