Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

replacing same reference more then one times #77

Open
cbfranca opened this issue Sep 20, 2017 · 1 comment
Open

replacing same reference more then one times #77

cbfranca opened this issue Sep 20, 2017 · 1 comment

Comments

@cbfranca
Copy link

// Rewrite references to file names which have been renamed by gulp-rev-all
gulp.task('fingerprintReplace', ['fingerprintGenerate'], () => {

  if (config.production) {

    // We only need file name without directories
    const stripDirectories = function (filename) {
      return filename.split('/').slice(0).pop();
    };


    return gulp.src([config.folder.build + '**/*', '!' + config.folder.build + 'rev-manifest.json'])      
      .pipe(revReplace({
        manifest: gulp.src(config.folder.build + 'rev-manifest.json'),
        modifyUnreved: stripDirectories,
        modifyReved: stripDirectories
      }))
      .pipe(gulp.dest(config.folder.build))
      .pipe(size({
        title: 'dist size'
      }));
  }

});

Print 01 - Console Errors
Print 02 - Manifest.json

Obs: Only occurs in some files

@tj-kev
Copy link

tj-kev commented Jan 29, 2018

Did you find a solution to this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants