Gulp Usemin not copying files or concatenating?

204 views Asked by At

The goal is for "usemin" to copy and concatenate the files referenced in my index.html into the build2 folder. Neither concatenation or copying of assets(CSS, js) is occurring when the Gulp task is created. Is there something overlooked?

File Structure:

/admin/build/index.html
/admin/build/css/.css
/admin/build/js/
.js
/admin/build2/index.html -->copied file
/admin/gulpfile.js

JavaScript:

var  concat = require('gulp-concat'),
  uglify = require('gulp-uglify'),
  usemin = require('gulp-usemin'),
  rev = require('gulp-rev');
  error = require('gulp-error'); 

gulp.task('usemin', function(){
  return gulp.src('build/index.html')
  .pipe(error('build/index.html'))
  .pipe( usemin({
     // assetDir: 'vendors',
     css: [rev(), 'concat']
  }).pipe( gulp.dest('build2') )
  )
}); 

HTML:
<!-- build:css css/deps.css -->
ink href="../vendors/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet">
<link href="../vendors/font-awesome/css/font-awesome.min.css" rel="stylesheet">
<link href="../vendors/nprogress/nprogress.css" rel="stylesheet"> <!-- endbuild-->
<!-- build:css css/customBuild.css -->
<link href="../build/css/custom.css" rel="stylesheet">
<!-- endbuild-->

0

There are 0 answers