Implemented cmdaction, tested on windows only