Add Grunt

This commit is contained in:
Sofya Ilinova 2014-12-31 22:49:19 +03:00
parent 7e324cd3bf
commit 26b5ac3fe8
4 changed files with 46 additions and 2 deletions

View file

@ -1,3 +1,3 @@
{
"directory": "chrome_point_plus/vendor"
"directory": "vendor"
}

1
.gitignore vendored
View file

@ -2,3 +2,4 @@ chrome_point_plus/vendor/
/nbproject/private/
node_modules/
publish
vendor/

41
Gruntfile.js Normal file
View file

@ -0,0 +1,41 @@
var vendorCopy = [
'jquery/jquery.min.js',
'fancybox/source/jquery.fancybox.pack.js',
'fancybox/source/helpers/jquery.fancybox-media.js',
'fancybox/source/jquery.fancybox.css',
'markitup/markitup/jquery.markitup.js',
'markitup/markitup/skins/markitup/style.css'
].map(function(file) {
return {
src: 'vendor/' + file,
dest: 'chrome_point_plus/vendor/' + file
};
});
vendorCopy.push({
expand: true,
src: [ 'vendor/fancybox/source/*.png' ],
dest: 'chrome_point_plus/'
});
module.exports = function(grunt) {
// Настройки
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
// Что копировать
copy: {
main: {
files: vendorCopy
}
}
});
// Загрузить плагины
grunt.loadNpmTasks('grunt-contrib-copy');
// Что выполнять по команде `grunt`
grunt.registerTask('default', [ 'copy' ]);
};

View file

@ -13,6 +13,8 @@
"author": "\"Alexey Skobkin\"",
"license": "MIT",
"devDependencies": {
"bower": "^1.3.12"
"bower": "^1.3.12",
"grunt": "^0.4.5",
"grunt-contrib-copy": "^0.7.0"
}
}