title: How to pipe to another task in Gulp?
body: <p>I try to DRY my gulpfile. There I have small duplication of code I not comfortable with. How can this be made better?</p>
  
  
  
  <pre class="lang-js prettyprint-override"><code>gulp.task('scripts', function() {
    return gulp.src('src/scripts/**/*.coffee')
      .pipe(coffeelint())
      .pipe(coffeelint.reporter())
      .pipe(coffee())
      .pipe(gulp.dest('dist/scripts/'))
      .pipe(gulp.src('src/index.html'))  // this
      .pipe(includeSource())             // needs
      .pipe(gulp.dest('dist/'))          // DRY
  });
  
  gulp.task('index', function() {
    return gulp.src('src/index.html')
      .pipe(includeSource())
      .pipe(gulp.dest('dist/'))
  });
  </code></pre>
  
  <p>I got <code>index</code> as a separate task, since I need to watch <code>src/index.html</code> to livereload. But I'm also watching my <code>.coffee</code> sources and when they change, I need to update <code>src/index.html</code> as well.</p>
  
  <p>How can I pipe to <code>index</code> in <code>scripts</code>?</p>