25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

39 lines
842 B

  1. /**
  2. * Copyright © Magento, Inc. All rights reserved.
  3. * See COPYING.txt for license details.
  4. */
  5. 'use strict';
  6. var combo = require('./combo'),
  7. themes = require('../tools/files-router').get('themes'),
  8. _ = require('underscore');
  9. var themeOptions = {};
  10. _.each(themes, function(theme, name) {
  11. themeOptions[name] = {
  12. cmd: combo.collector.bind(combo, name)
  13. };
  14. });
  15. var execOptions = {
  16. all : {
  17. cmd: function () {
  18. var cmdPlus = (/^win/.test(process.platform) == true) ? ' & ' : ' && ',
  19. command;
  20. command = _.map(themes, function(theme, name) {
  21. return combo.collector(name);
  22. }).join(cmdPlus);
  23. return 'echo ' + command;
  24. }
  25. }
  26. };
  27. /**
  28. * Execution into cmd
  29. */
  30. module.exports = _.extend(themeOptions, execOptions);