Let's see how to Create basic plug-in here.
Create basic plug-in
install grunt-init
$ npm install -g grunt-init
grunt-init-gruntplug-in.git
$ git clone git://github.com/gruntjs/grun-init-gruntplug-in.git ~/.grunt-init/gruntplug-in
$ grunt-init gruntplug-in
$ npm install
$ npm publish