release.js
function updateBowerVersion () {
    start('Updating bower version...');
    const options = { cwd: './bower-material' };
    const bower   = require(options.cwd + '/bower.json'),
          pkg     = require(options.cwd + '/package.json');
    // update versions in config files
    bower.version = pkg.version = newVersion;
    fs.writeFileSync(options.cwd + '/package.json', JSON.stringify(pkg, null, 2));
    fs.writeFileSync(options.cwd + '/bower.json', JSON.stringify(bower, null, 2));
    done();
    start('Building bower files...');
    // build files for bower
    exec([
      'rm -rf dist',
      'gulp build',
      'gulp build-all-modules --mode=default',
      'gulp build-all-modules --mode=closure',
      'rm -rf dist/demos'
     ]);
    done();
    start('Copy files into bower repo...');
    // copy files over to bower repo
    exec([
           'cp -Rf ../dist/* ./',
           'git add -A',
           `git commit -m "release: version ${newVersion}"`,
           'rm -rf ../dist'
         ], options);
    done();
    // add steps to push script
    pushCmds.push(
      comment('push to bower (master and tag) and publish to npm'),
      'cd ' + options.cwd,
      'cp ../CHANGELOG.md .',
      'git add CHANGELOG.md',
      'git commit --amend --no-edit',
      `git tag -f v${newVersion}`,
      'git pull --rebase --strategy=ours',
      'git push',
      'git push --tags',
      'rm -rf .git/',
      'npm publish',
      'cd ..'
    );
  }
function updateBowerVersion () {
    start('Updating bower version...');
    const options = { cwd: './bower-material' };
    const bower   = require(options.cwd + '/bower.json'),
          pkg     = require(options.cwd + '/package.json');
    // update versions in config files
    bower.version = pkg.version = newVersion;
    fs.writeFileSync(options.cwd + '/package.json', JSON.stringify(pkg, null, 2));
    fs.writeFileSync(options.cwd + '/bower.json', JSON.stringify(bower, null, 2));
    done();
    start('Building bower files...');
    // build files for bower
    exec([
      'rm -rf dist',
      'gulp build',
      'gulp build-all-modules --mode=default',
      'gulp build-all-modules --mode=closure',
      'rm -rf dist/demos'
     ]);
    done();
    start('Copy files into bower repo...');
    // copy files over to bower repo
    exec([
           'cp -Rf ../dist/* ./',
           'git add -A',
           `git commit -m "release: version ${newVersion}"`,
           'rm -rf ../dist'
         ], options);
    done();
    // add steps to push script
    pushCmds.push(
      comment('push to bower (master and tag) and publish to npm'),
      'cd ' + options.cwd,
      'cp ../CHANGELOG.md .',
      'git add CHANGELOG.md',
      'git commit --amend --no-edit',
      `git tag -f v${newVersion}`,
      'git pull --rebase --strategy=ours',
      'git push',
      'git push --tags',
      'rm -rf .git/',
      'npm publish',
      'cd ..'
    );
  }
function updateBowerVersion ( ) { start ( 'Updating bower version...' ) ; const options = { cwd : './bower-material' } ; const bower = require ( options . cwd + '/bower.json' ) , pkg = require ( options . cwd + '/package.json' ) ; // update versions in config files bower . version = pkg . version = newVersion ; fs . writeFileSync ( options . cwd + '/package.json' , JSON . stringify ( pkg , null , 2 ) ) ; fs . writeFileSync ( options . cwd + '/bower.json' , JSON . stringify ( bower , null , 2 ) ) ; done ( ) ; start ( 'Building bower files...' ) ; // build files for bower exec ( [ 'rm -rf dist' , 'gulp build' , 'gulp build-all-modules --mode=default' , 'gulp build-all-modules --mode=closure' , 'rm -rf dist/demos' ] ) ; done ( ) ; start ( 'Copy files into bower repo...' ) ; // copy files over to bower repo exec ( [ 'cp -Rf ../dist/* ./' , 'git add -A' , ` ${ newVersion } ` , 'rm -rf ../dist' ] , options ) ; done ( ) ; // add steps to push script pushCmds . push ( comment ( 'push to bower (master and tag) and publish to npm' ) , 'cd ' + options . cwd , 'cp ../CHANGELOG.md .' , 'git add CHANGELOG.md' , 'git commit --amend --no-edit' , ` ${ newVersion } ` , 'git pull --rebase --strategy=ours' , 'git push' , 'git push --tags' , 'rm -rf .git/' , 'npm publish' , 'cd ..' ) ; }
updates the version for bower-material in package.json and bower.json
updates the version for bower - material in package . json and bower . json