gulpfile.js
function inc(importance) {
    var git = require('gulp-git'),
        bump = require('gulp-bump'),
        filter = require('gulp-filter'),
        tag_version = require('gulp-tag-version');

    // get all the files to bump version in
    return gulp.src(['./package.json', './bower.json'])
        // bump the version number in those files
        .pipe(bump({type: importance}))
        // save it back to filesystem
        .pipe(gulp.dest('./'))
        // commit the changed version number
        .pipe(git.commit('bumps package version'))

        // read only one file to get the version number
        .pipe(filter('package.json'))
        // **tag it in the repository**
        .pipe(tag_version());
}
function inc(importance) {
    var git = require('gulp-git'),
        bump = require('gulp-bump'),
        filter = require('gulp-filter'),
        tag_version = require('gulp-tag-version');

    // get all the files to bump version in
    return gulp.src(['./package.json', './bower.json'])
        // bump the version number in those files
        .pipe(bump({type: importance}))
        // save it back to filesystem
        .pipe(gulp.dest('./'))
        // commit the changed version number
        .pipe(git.commit('bumps package version'))

        // read only one file to get the version number
        .pipe(filter('package.json'))
        // **tag it in the repository**
        .pipe(tag_version());
}
function inc ( importance ) { var git = require ( 'gulp-git' ) , bump = require ( 'gulp-bump' ) , filter = require ( 'gulp-filter' ) , tag_version = require ( 'gulp-tag-version' ) ; // get all the files to bump version in return gulp . src ( [ './package.json' , './bower.json' ] ) // bump the version number in those files . pipe ( bump ( { type : importance } ) ) // save it back to filesystem . pipe ( gulp . dest ( './' ) ) // commit the changed version number . pipe ( git . commit ( 'bumps package version' ) ) // read only one file to get the version number . pipe ( filter ( 'package.json' ) ) // **tag it in the repository** . pipe ( tag_version ( ) ) ; }
Versioning tasks 
Increments a version value within the package json and bower json
Versioning tasks Increments a version value within the package json and bower json