Я хочу скопировать содержимое /pckg
в /dist
с помощью grunt.js.
Вот структура:
|-- folder1
| |
| |-- folder2
| |
| |-- pckg
| |
| |--myfolder
| | |
| | |-- myfiles
| |
| |--myfiles
|
|
|-- dist
|
|--myfolder
| |
| |-- myfiles
|
|--myfiles
Здесь мой Gruntfile.js
module.exports = function (grunt) {
// Package configuration
grunt.initConfig({
// Metadata
pkg: grunt.file.readJSON('package.json'),
//Copy files
copy: {
main: {
expand: true,
src: 'folder1/folder2/pckg/**',
dest: 'dest/'
}
}
});
// Load the plugin that provides the "copy" task.
grunt.loadNpmTasks('grunt-contrib-copy');
// Default task(s).
grunt.registerTask('default', ['copy']);
};
Когда я запускаю Grunt, он сохраняет путь. Он копирует все в dit/folder1/folder2/pckg
.
Что не так?
Спасибо за вашу помощь!