Reputation: 1109
My structure is like below. I want to copy assets folder from app directory to dist directory?
app
assets
imgs
css
fonts
index.html
dist
Upvotes: 0
Views: 92
Reputation: 14401
Set the current working directory to app. Select all subdirs and files of assets. Set the destination to dest.
grunt.initConfig({
copy: {
dist: {
cwd: 'app',
src: ['assets/**/*'],
dest: 'dist/',
expand: true
}
}
});
grunt.loadNpmTasks('grunt-contrib-copy');
grunt.registerTask('default', ['copy:dist']);
Upvotes: 1