Guest User

Untitled

a guest
Feb 28th, 2015
257
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. module.exports = (grunt)->
  2.     grunt.initConfig
  3.         pkg: grunt.fimodule.exports = (grunt)->
  4.     grunt.initConfig
  5.         pkg: grunt.file.readJSON('package.json')
  6.  
  7.         slim:
  8.             dist:
  9.                 files:
  10.                     'build/index.html': 'index.slim'
  11.                     'build/templates/index.html': 'templates/index.slim'
  12.                     'build/templates/form.html': 'templates/form.slim'
  13.                     'build/templates/new.html': 'templates/new.slim'
  14.                     'build/templates/edit.html': 'templates/edit.slim'
  15.         sass:
  16.             dist:
  17.                 options:
  18.                     cacheLocation: 'temp/sass-cache'
  19.                 files:
  20.                     'build/css/style.css': ['assets/css/style.scss']
  21.  
  22.         coffee:
  23.             compileWithMaps:
  24.                 options:
  25.                     sourceMap: true
  26.                 files:
  27.                     'temp/js/app.js': [
  28.                         'assets/js/app.coffee',
  29.                         'assets/js/controllers/DataController.coffee' ]
  30.  
  31.         uglify:
  32.             dist:
  33.                 options:
  34.                     sourceMap: true
  35.                     compress:
  36.                         drop_console: true
  37.                 files:
  38.                     'temp/js/app.min.js': [ 'temp/js/app.js' ]
  39.  
  40.         concat:
  41.             options:
  42.                 separator: '\n'
  43.             app:
  44.                 src: [  'node_modules/angular/angular.min.js',
  45.                         'node_modules/angular-ui-router/release/angular-ui-router.min.js',
  46.                         'temp/js/app.min.js' ]
  47.                 dest: 'build/js/app.min.js'
  48.  
  49.         watch:
  50.             options:
  51.                 livereload: true
  52.             gruntfile:
  53.                 files: 'Gruntfile.coffee'
  54.                 tasks: ['apply']
  55.             scss:
  56.                 files: [ 'assets/css/style.scss' ]
  57.                 tasks: ['apply']
  58.             slim:
  59.                 files: [ 'index.slim',
  60.                          'templates/form.slim']
  61.                 tasks: ['apply']
  62.             coffee:
  63.                 files: [ 'assets/js/app.coffee',
  64.                          'assets/js/controllers/DataController.coffee']
  65.                 tasks: ['apply']
  66.  
  67.     grunt.loadNpmTasks 'grunt-slim'
  68.     grunt.loadNpmTasks 'grunt-contrib-sass'
  69.     grunt.loadNpmTasks 'grunt-contrib-coffee'
  70.     grunt.loadNpmTasks 'grunt-contrib-uglify'
  71.     grunt.loadNpmTasks 'grunt-contrib-concat'
  72.     grunt.loadNpmTasks 'grunt-contrib-watch'
  73.     grunt.loadNpmTasks 'grunt-newer'
  74.  
  75.     grunt.registerTask 'default', ['slim', 'sass', 'coffee', 'uglify', 'concat']
  76.     grunt.registerTask 'apply', 'apply changes in code', ()->
  77.         grunt.task.run 'newer:slim'
  78.         grunt.task.run 'newer:sass'
  79.         grunt.task.run 'newer:coffee'
  80.         grunt.task.run 'newer:uglify'
  81.         grunt.task.run 'newer:concat'
  82.  
  83. le.readJSON('package.json')
  84.  
  85.         slim:
  86.             dist:
  87.                 files:
  88.                     'build/index.html': 'index.slim'
  89.                     'build/templates/index.html': 'templates/index.slim'
  90.                     'build/templates/form.html': 'templates/form.slim'
  91.                     'build/templates/new.html': 'templates/new.slim'
  92.                     'build/templates/edit.html': 'templates/edit.slim'
  93.         sass:
  94.             dist:
  95.                 options:
  96.                     cacheLocation: 'temp/sass-cache'
  97.                 files:
  98.                     'build/css/style.css': ['assets/css/style.scss']
  99.  
  100.         coffee:
  101.             compileWithMaps:
  102.                 options:
  103.                     sourceMap: true
  104.                 files:
  105.                     'temp/js/app.js': [
  106.                         'assets/js/app.coffee',
  107.                         'assets/js/controllers/DataController.coffee' ]
  108.  
  109.         uglify:
  110.             dist:
  111.                 options:
  112.                     sourceMap: true
  113.                     compress:
  114.                         drop_console: true
  115.                 files:
  116.                     'temp/js/app.min.js': [ 'temp/js/app.js' ]
  117.  
  118.         concat:
  119.             options:
  120.                 separator: '\n'
  121.             app:
  122.                 src: [  'node_modules/angular/angular.min.js',
  123.                         'node_modules/angular-ui-router/release/angular-ui-router.min.js',
  124.                         'temp/js/app.min.js' ]
  125.                 dest: 'build/js/app.min.js'
  126.  
  127.         watch:
  128.             options:
  129.                 livereload: true
  130.             gruntfile:
  131.                 files: 'Gruntfile.coffee'
  132.                 tasks: ['apply']
  133.             scss:
  134.                 files: [ 'assets/css/style.scss' ]
  135.                 tasks: ['apply']
  136.             slim:
  137.                 files: [ 'index.slim',
  138.                          'templates/form.slim']
  139.                 tasks: ['apply']
  140.             coffee:
  141.                 files: [ 'assets/js/app.coffee',
  142.                          'assets/js/controllers/DataController.coffee']
  143.                 tasks: ['apply']
  144.  
  145.     grunt.loadNpmTasks 'grunt-slim'
  146.     grunt.loadNpmTasks 'grunt-contrib-sass'
  147.     grunt.loadNpmTasks 'grunt-contrib-coffee'
  148.     grunt.loadNpmTasks 'grunt-contrib-uglify'
  149.     grunt.loadNpmTasks 'grunt-contrib-concat'
  150.     grunt.loadNpmTasks 'grunt-contrib-watch'
  151.     grunt.loadNpmTasks 'grunt-newer'
  152.  
  153.     grunt.registerTask 'default', ['slim', 'sass', 'coffee', 'uglify', 'concat']
  154.     grunt.registerTask 'apply', 'apply changes in code', ()->
  155.         grunt.task.run 'newer:slim'
  156.         grunt.task.run 'newer:sass'
  157.         grunt.task.run 'newer:coffee'
  158.         grunt.task.run 'newer:uglify'
  159.         grunt.task.run 'newer:concat'
  160.  
  161. module.exports = (grunt)->
  162.     grunt.initConfig
  163.         pkg: grunt.file.readJSON('package.json')
  164.  
  165.         slim:
  166.             dist:
  167.                 files:
  168.                     'build/index.html': 'index.slim'
  169.                     'build/templates/index.html': 'templates/index.slim'
  170.                     'build/templates/form.html': 'templates/form.slim'
  171.                     'build/templates/new.html': 'templates/new.slim'
  172.                     'build/templates/edit.html': 'templates/edit.slim'
  173.         sass:
  174.             dist:
  175.                 options:
  176.                     cacheLocation: 'temp/sass-cache'
  177.                 files:
  178.                     'build/css/style.css': ['assets/css/style.scss']
  179.  
  180.         coffee:
  181.             compileWithMaps:
  182.                 options:
  183.                     sourceMap: true
  184.                 files:
  185.                     'temp/js/app.js': [
  186.                         'assets/js/app.coffee',
  187.                         'assets/js/controllers/DataController.coffee' ]
  188.  
  189.         uglify:
  190.             dist:
  191.                 options:
  192.                     sourceMap: true
  193.                     compress:
  194.                         drop_console: true
  195.                 files:
  196.                     'temp/js/app.min.js': [ 'temp/js/app.js' ]
  197.  
  198.         concat:
  199.             options:
  200.                 separator: '\n'
  201.             app:
  202.                 src: [  'node_modules/angular/angular.min.js',
  203.                         'node_modules/angular-ui-router/release/angular-ui-router.min.js',
  204.                         'temp/js/app.min.js' ]
  205.                 dest: 'build/js/app.min.js'
  206.  
  207.         watch:
  208.             options:
  209.                 livereload: true
  210.             gruntfile:
  211.                 files: 'Gruntfile.coffee'
  212.                 tasks: ['apply']
  213.             scss:
  214.                 files: [ 'assets/css/style.scss' ]
  215.                 tasks: ['apply']
  216.             slim:
  217.                 files: [ 'index.slim',
  218.                          'templates/form.slim']
  219.                 tasks: ['apply']
  220.             coffee:
  221.                 files: [ 'assets/js/app.coffee',
  222.                          'assets/js/controllers/DataController.coffee']
  223.                 tasks: ['apply']
  224.  
  225.     grunt.loadNpmTasks 'grunt-slim'
  226.     grunt.loadNpmTasks 'grunt-contrib-sass'
  227.     grunt.loadNpmTasks 'grunt-contrib-coffee'
  228.     grunt.loadNpmTasks 'grunt-contrib-uglify'
  229.     grunt.loadNpmTasks 'grunt-contrib-concat'
  230.     grunt.loadNpmTasks 'grunt-contrib-watch'
  231.     grunt.loadNpmTasks 'grunt-newer'
  232.  
  233.     grunt.registerTask 'default', ['slim', 'sass', 'coffee', 'uglify', 'concat']
  234.     grunt.registerTask 'apply', 'apply changes in code', ()->
  235.         grunt.task.run 'newer:slim'
  236.         grunt.task.run 'newer:sass'
  237.         grunt.task.run 'newer:coffee'
  238.         grunt.task.run 'newer:uglify'
  239.         grunt.task.run 'newer:concat'
Advertisement
Add Comment
Please, Sign In to add comment