Advertisement
Guest User

Untitled

a guest
May 2nd, 2016
117
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.43 KB | None | 0 0
  1. module.exports = function(grunt) {
  2.  
  3. grunt.initConfig({
  4.  
  5. pkg: grunt.file.readJSON('package.json'),
  6.  
  7. secret: grunt.file.readJSON('secret.json'),
  8.  
  9. sftp: {
  10.  
  11. dev: {
  12.  
  13. options: {
  14.  
  15. ignoreErrors:false,
  16.  
  17. host: '<%= secret.host %>',
  18.  
  19. username: '<%= secret.username %>',
  20.  
  21. password: '<%= secret.password %>',
  22.  
  23. showProgress: true,
  24.  
  25. },
  26.  
  27. }
  28.  
  29. },
  30.  
  31. watch: {
  32.  
  33. file_changes: {
  34.  
  35. files: ['**','!{node_modules,artifacts,sql,logs,.settings, *.pdf}/**'],
  36. tasks: [''],
  37. options: {
  38. interval: 100,
  39. spawn: false,
  40.  
  41. },
  42.  
  43. },
  44.  
  45. }
  46.  
  47. });
  48.  
  49.  
  50. grunt.event.on('watch', function(action, filepath) {
  51.  
  52. grunt.log.write('-----------------------------------------------------------------------------------------------');
  53.  
  54. grunt.config('sftp.dev.options.directoryPermissions', "755");
  55.  
  56. grunt.config('sftp.options.directoryPermissions', "755");
  57.  
  58. grunt.config('sftp.options.directoryPermissions', "755");
  59.  
  60. //grunt.config('sftp.dev.options.path', "/aaaaaaa");
  61.  
  62. });
  63.  
  64. grunt.loadNpmTasks('grunt-ssh');
  65.  
  66. grunt.loadNpmTasks('grunt-contrib-watch');
  67.  
  68. grunt.registerTask('default', ['watch']);
  69.  
  70. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement