git-push.js 583 B

1234567891011121314151617181920212223242526
  1. /**
  2. * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
  3. * For licensing, see LICENSE.md.
  4. */
  5. 'use strict';
  6. const git = require( '../utils/git' );
  7. const PassThrough = require( 'stream' ).PassThrough;
  8. /**
  9. * Pushes changes of current branch in repository to default origin.
  10. *
  11. * Example:
  12. *
  13. * gulp exec --task git-push
  14. *
  15. * @param {String} workdir
  16. * @returns {Stream}
  17. */
  18. module.exports = function executeGitPush( workdir ) {
  19. git.push( workdir );
  20. // Return dummy stream to inform gulp about finishing task.
  21. return new PassThrough();
  22. };