Moved GetExecutableCommand to common