   .pipe gulp.dest(homePath)
 
   gulp.src('')
-  .pipe installBundle()
-  .pipe installBundle()
-  .pipe cleanBundle()
+  .pipe pluginUpdate()
+  .pipe pluginUpdate()
+  .pipe pluginClean()
 
 gulp.task 'nodev', ->
   del(pluginPath, {force: true})

remotePluginPath = 'razor-x/vimrc'
pluginPath = "#{homePath}/.vim/bundle/vimrc"

installBundle = () -> $.shell("sh -c '</dev/tty vim -c PluginUpdate -c quitall'")
cleanBundle = () -> $.shell("sh -c '</dev/tty vim -c PluginClean -c quitall'")

gulp.task 'default', ['watch']


  .pipe gulp.dest(homePath)

  gulp.src('')
  .pipe pluginUpdate()
  .pipe pluginUpdate()
  .pipe pluginClean()

gulp.task 'clean', ->
  del(pluginPath, {force: true})

gulp.task 'install', ['build'], ->
  gulp.src('')
  .pipe pluginInstall()

gulp.task 'build', ['clean'], ->
  gulp.src('plugin/**/*.vim')
