some changes
some refactoring. new command modification added.