I can't get livereload to work when using node.js and gulp

My gulpfile is as follows:

var gulp = require('gulp'),
    connect = require('gulp-connect'),
    sass = require('gulp-ruby-sass'),
    autoprefixer = require('gulp-autoprefixer'),
    minifycss = require('gulp-minify-css'),
    jshint = require('gulp-jshint'),
    uglify = require('gulp-uglify'),
    imagemin = require('gulp-imagemin'),
    rename = require('gulp-rename'),
    clean = require('gulp-clean'),
    concat = require('gulp-concat'),
    notify = require('gulp-notify'),
    cache = require('gulp-cache'),
    livereload = require('gulp-livereload');

gulp.task('styles', function() {
  return gulp.src('main.scss')

    .pipe(autoprefixer('last 2 version', 'safari 5', 'ie 8', 'ie 9', 'opera 12.$
    .pipe(gulp.dest('css'))
    .pipe(rename({suffix: '.min'}))
    .pipe(minifycss())
    .pipe(gulp.dest('css'));
});

    gulp.task('default', function() {
    gulp.start('styles');
    gulp.start('server');
    gulp.start('watch');
});


gulp.task('server', function() {
    connect.server({
      livereload:true
    });
});


gulp.task('indexChange',function(){
    console.log('index has changed');
    connect.reload();
} );

gulp.task('watch', function() {

  gulp.watch('index.html', ['indexChange']);


});

when I change my index.html file the 'indexChange' task runs and the console outputs 'index has changed', however connect.reload() does nothing.

I've check the liverload port and the connect server port so I know both are running. But I can't figure out what code I'm missing to get livereload to work.

What am I doing wrong?

You need to return the pipe into connect.reload(); for it to work, try this:

// add gulp-watch
var watch = require('gulp-watch');

gulp.task('indexChange',function(){
    console.log('index has changed');
} );

gulp.task('watch', function() {
  watch({glob: './index.html'}, ['indexChange']).pipe(connect.reload());
});