Say I have this directory setup:
+-- gruntfile.js
|
+-- src/
| |
| +-- lib/
| |
| +-- imgs/**
| |
| +-- js/**
And I want to create a distribution folder using grunt-contrib-copy:
+-- gruntfile.js
|
+-- app/
…
Hi I'm using this filter
var fs = require('fs');
function onlyNew(target) {
return function(filepath) {
var src = fs.statSync(filepath).mtime.getTime();
var dest = grunt.config(target.concat('dest')) +
…
There is source folder and publish folder in the project. I want to copy all files and folders from source to publish.
Related code from Gruntfiles.js:
grunt.initConfig({
copy: {
main: {
files: [
{ src:…
I'm trying to remove my live reload script from my index.html file dynamically using Grunt's copy plugin.
The part of my Gruntfile with the code in question is here:
copy: {
main: {
files: [
{
…
I'm copying some folders with grunt-contrib-copy. I'm trying to exclude a subdirectory in the root. I can prevent the contents of the _sprites folder from being copied, but inevitably the sprites copy is always copied. How do I prevent the folder…
I'm fairly new to Grunt. I am trying to copy each sub directory from one location and place each in another destination directory. I am doing this in a custom grunt task because I cannot be sure how many sub directories will exist in the source…
I am trying to run a simple grunt task using grunt-contrib-copy, but it dies immediately on reaching the copy task, with this message:
Running "copy:main" (copy) task
Warning: EPERM, operation not permitted 'C:\Documents and Settings' Use --force…
I am trying to copy cshtml files to the production folder.
the files are located in the path:
a\b\c\d and the destination is a\b\e
the task is
copy: {
copyCSHtml: {
src: '../NGWeb/client/app/appComponents/**/*.cshtml',
…
Basically, I want to have a partial called _variables.scss for production and _variables-test.scss for testing. I need to set a path variable for font-awesome that will be different in production than when simply testing using "grunt serve" because…
I am trying do the following:
FOLDERS.GRUNT = "js/grunt"
grunt.initConfig({
//copies from .tmp to final locations
copy: {
dist: {
files: [{
expand: true,
dot: true,
dest: FOLDERS.GRUNT,
src:…
I'm trying to copy everything in my css directory, including any nested folders and files in those folders.
copy: {
main: {
options: {
expand: true
},
files: [
{ src:…
Update
Part of the problem is that front/styles contains both css and scss files. I only want to copy css files.
Original
So the copy task from grunt-contrib-copy should be doing one thing. Copying all the *.css files from front/styles and move them…
I'm trying to create a very simple copy task but it seems grunt-copy is not made for my usecase :-(.
All I needed is the following:
Source directory structure:
vendor
L subdir1
L assets
L subdir2
L subdir3
…