shannonmoeller / gulp-hb

A sane Gulp plugin to compile Handlebars templates. Useful as a static site generator.

Home Page:http://npm.im/gulp-hb

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Nothing happening at all

aish1550 opened this issue · comments

I have a very simple setup that I am trying to get working with the gulp-webapp yeoman generator.

const hb = require('gulp-hb');

gulp.task('pages', function () {
  return gulp
    .src('./src/posts/*.{html,hbs}')
    .pipe(hb({
      partials: './src/assets/partials/**/*.hbs'
    }))
    .pipe(gulp.dest('./'));
});

gulp.task('serve', ['pages','styles', 'scripts', 'fonts'], () => {
  browserSync({
    notify: false,
    port: 9000,
    server: {
      baseDir: ['.tmp', 'app'],
      routes: {
        '/bower_components': 'bower_components'
      }
    }
  });

  gulp.watch([
    'app/*.html',
    'app/images/**/*',
    '.tmp/fonts/**/*'
  ]).on('change', reload);

  gulp.watch('app/styles/**/*.scss', ['styles']);
  gulp.watch('app/scripts/**/*.js', ['scripts']);
  gulp.watch('app/fonts/**/*', ['fonts']);
  gulp.watch('bower.json', ['wiredep', 'fonts']);
});

But nothing happens. No files created. Is it just one of things where I can't have my cake and eat it too? Or in other words, I can't use the gulp-webapp generator and add gulp-hb to it?

I haven't used gulp-webapp. Have you tried running gulp pages directly instead of via the serve task?

Closing due to inactivity and no similar reported issues. Feel free to reopen if you're still having problems.