Gulp watch SyntaxError

I install npm install. After gulp and bower.
when I run “gulp watch” it gives me an error.

I tried to reinstall npm and clear cache and install again everything but still the same. Sage theme is activated. I change manifest.json “devUrl”: “http://localhost/smartquotes” .

this is my output when i ran “gulp watch”

/Users/alan/Desktop/Sites/smartquotes/wp-content/themes/squotes/node_modules/gulp-autoprefixer/node_modules/postcss/node_modules/source-map/lib/source-map/source-map-generator.js:351
});
 ^
SyntaxError: Unexpected token )
at exports.runInThisContext (vm.js:73:16)
at Module._compile (module.js:443:25)
at Object.Module._extensions..js (module.js:478:10)
at Module.load (module.js:355:32)
at Function.Module._load (module.js:310:12)
at Module.require (module.js:365:17)
at require (module.js:384:17)
at Object.<anonymous> (/Users/alan/Desktop/Sites/smartquotes/wp-content/themes/squotes/node_modules/gulp-autoprefixer/node_modules/postcss/node_modules/source-map/lib/source-map.js:6:30)
at Module._compile (module.js:460:26)
at Object.Module._extensions..js (module.js:478:10)

when i ran: npm list --depth=0

sage@8.2.1 /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/squotes
├── asset-builder@1.1.0
├── browser-sync@2.8.0
├── browserslist@0.5.0 extraneous
├── del@1.2.0
├── findup-sync@0.1.2 extraneous
├── gulp@3.9.0
├── gulp-autoprefixer@2.3.1
├── gulp-changed@1.2.1
├── gulp-concat@2.6.0
├── gulp-flatten@0.0.4
├── gulp-if@1.2.5
├── gulp-imagemin@2.3.0
├── gulp-jshint@1.11.2
├── gulp-less@3.0.3
├── gulp-minify-css@1.2.0
├── gulp-plumber@1.0.1
├── gulp-rename@1.2.2
├── gulp-rev@3.0.1
├── gulp-sass@2.0.4
├── gulp-sourcemaps@1.5.2
├── gulp-uglify@1.2.0
├── imagemin-pngcrush@4.1.0
├── jshint-stylish@1.0.2
├── lazypipe@0.2.4
├── merge-stream@0.1.8
├── minimist@1.1.1
├── run-sequence@1.1.2
├── traverse@0.6.6
└── wiredep@2.2.2

npm ERR! extraneous: browserslist@0.5.0 /Users/alan/Desktop/Sites/smartquotes/wp-    content/themes/squotes/node_modules/browserslist
npm ERR! max depth reached: anymatch@^1.3.0, required by browser-sync@2.8.0
npm ERR! max depth reached: async-each-series@^0.1.1, required by browser-sync@2.8.0
npm ERR! max depth reached: browser-sync-client@^2.2.1, required by browser-sync@2.8.0
npm ERR! max depth reached: browser-sync-ui@^0.5.12, required by browser-sync@2.8.0
npm ERR! max depth reached: chokidar@^1.0.4, required by browser-sync@2.8.0
npm ERR! max depth reached: connect@^3.4.0, required by browser-sync@2.8.0
npm ERR! max depth reached: dev-ip@^1.0.1, required by browser-sync@2.8.0
npm ERR! max depth reached: easy-extender@^2.3.1, required by browser-sync@2.8.0
npm ERR! max depth reached: eazy-logger@^2.1.2, required by browser-sync@2.8.0
npm ERR! max depth reached: emitter-steward@^0.0.1, required by browser-sync@2.8.0
npm ERR! max depth reached: foxy@^11.1.1, required by browser-sync@2.8.0
npm ERR! max depth reached: immutable@^3.7.4, required by browser-sync@2.8.0
npm ERR! max depth reached: localtunnel@^1.6.0, required by browser-sync@2.8.0
npm ERR! max depth reached: lodash@^3.9.3, required by browser-sync@2.8.0
npm ERR! max depth reached: longest@^1.0.1, required by browser-sync@2.8.0
npm ERR! max depth reached: meow@^3.3.0, required by browser-sync@2.8.0
npm ERR! max depth reached: opn@^2.0.1, required by browser-sync@2.8.0
npm ERR! max depth reached: pad-left@^1.0.2, required by browser-sync@2.8.0
npm ERR! max depth reached: portscanner@^1.0.0, required by browser-sync@2.8.0
npm ERR! max depth reached: query-string@^2.3.0, required by browser-sync@2.8.0
npm ERR! max depth reached: resp-modifier@^4.0.3, required by browser-sync@2.8.0
npm ERR! max depth reached: serve-index@^1.7.0, required by browser-sync@2.8.0
npm ERR! max depth reached: serve-static@^1.10.0, required by browser-sync@2.8.0
npm ERR! max depth reached: socket.io@^1.3.6, required by browser-sync@2.8.0
npm ERR! max depth reached: ua-parser-js@^0.7.9, required by browser-sync@2.8.0
npm ERR! max depth reached: ucfirst@0.0.1, required by browser-sync@2.8.0
npm ERR! extraneous: findup-sync@0.1.2 /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/squotes/node_modules/findup-sync

version npm: npm -v

2.13.1

when i ran update:

 npm install -g npm@latest
 npm ERR! Darwin 14.3.0
 npm ERR! argv "node" "/usr/local/bin/npm" "install" "-g" "npm@latest"
 npm ERR! node v0.12.7
 npm ERR! npm  v2.11.3
 npm ERR! path /usr/local/lib/node_modules/npm/doc/api
 npm ERR! code EACCES
 npm ERR! errno -13

 npm ERR! Error: EACCES, rmdir '/usr/local/lib/node_modules/npm/doc/api'
 npm ERR!     at Error (native)
 npm ERR!  { [Error: EACCES, rmdir '/usr/local/lib/node_modules/npm/doc/api']
 npm ERR!   errno: -13,
 npm ERR!   code: 'EACCES',
 npm ERR!   path: '/usr/local/lib/node_modules/npm/doc/api' }
 npm ERR!
 npm ERR! Please try running this command again as root/Administrator.
 npm ERR! error rolling back Error: EACCES, unlink '/usr/local/lib/node_modules/npm/lib/access.js'
 npm ERR! error rolling back     at Error (native)
 npm ERR! error rolling back  { [Error: EACCES, unlink '/usr/local/lib/node_modules/npm/lib/access.js']
 npm ERR! error rolling back   errno: -13,
 npm ERR! error rolling back   code: 'EACCES',
 npm ERR! error rolling back   path: '/usr/local/lib/node_modules/npm/lib/access.js' }

 npm ERR! Please include the following file with any support request:
 npm ERR!     /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/smartquotes/npm-debug.log

checking versions:

node -v && npm -v && gulp -v
v0.12.7
2.11.3
[17:23:21] CLI version 3.9.0
[17:23:21] Local version 3.9.0

when i ran:
npm cache clear && rm -rf node_modules && npm install

optipng-bin@3.0.2 postinstall /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/smartquotes/node_modules/gulp-imagemin/node_modules/imagemin/node_modules/imagemin-optipng/node_modules/optipng-bin
node lib/install.js

  ✔ optipng pre-build test passed successfully

gifsicle@3.0.1 postinstall /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/smartquotes/node_modules/gulp-imagemin/node_modules/imagemin/node_modules/imagemin-gifsicle/node_modules/gifsicle
node lib/install.js

  ✔ gifsicle pre-build test passed successfully

jpegtran-bin@3.0.4 postinstall /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/smartquotes/node_modules/gulp-imagemin/node_modules/imagemin/node_modules/imagemin-jpegtran/node_modules/jpegtran-bin
node lib/install.js

  ✔ jpegtran pre-build test passed successfully

pngcrush-bin@3.0.0 postinstall /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/smartquotes/node_modules/imagemin-pngcrush/node_modules/pngcrush-bin
node lib/install.js

  ✔ pngcrush pre-build test passed successfully

fsevents@0.3.6 install /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/smartquotes/node_modules/browser-sync/node_modules/chokidar/node_modules/fsevents
node-gyp rebuild

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory             '/Library/Developer/CommandLineTools' is a command line tools instance

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

  SOLINK_MODULE(target) Release/.node
  CXX(target) Release/obj.target/fse/fsevents.o
  SOLINK_MODULE(target) Release/fse.node

> utf-8-validate@1.1.0 install /Users/alan/Desktop/Sites/smartquotes/wp-    content/themes/smartquotes/node_modules/browser-    sync/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/utf-8-validate

node-gyp rebuild

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

  CXX(target) Release/obj.target/validation/src/validation.o
  SOLINK_MODULE(target) Release/validation.node

> bufferutil@1.1.0 install /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/smartquotes/node_modules/browser-sync/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/bufferutil
> node-gyp rebuild

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory     '/Library/Developer/CommandLineTools' is a command line tools instance

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

  CXX(target) Release/obj.target/bufferutil/src/bufferutil.o
  SOLINK_MODULE(target) Release/bufferutil.node

> utf-8-validate@1.1.0 install /Users/alan/Desktop/Sites/smartquotes/wp-    content/themes/smartquotes/node_modules/browser-sync/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/utf-8-validate
> node-gyp rebuild

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

  CXX(target) Release/obj.target/validation/src/validation.o
  SOLINK_MODULE(target) Release/validation.node

> bufferutil@1.1.0 install /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/smartquotes/node_modules/browser-sync/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/bufferutil
> node-gyp rebuild

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

  CXX(target) Release/obj.target/bufferutil/src/bufferutil.o
  SOLINK_MODULE(target) Release/bufferutil.node

> node-sass@3.2.0 install /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/smartquotes/node_modules/gulp-sass/node_modules/node-sass
> node scripts/install.js

Binary downloaded and installed at /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/smartquotes/node_modules/gulp-sass/node_modules/node-sass/vendor/darwin-x64-14/binding.node

> node-sass@3.2.0 postinstall /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/smartquotes/node_modules/gulp-sass/node_modules/node-sass
> node scripts/build.js

` /Users/alan/Desktop/Sites/smartquotes/wp-content/themes/smartquotes/node_modules/gulp-sass/node_modules/node-sass/vendor/darwin-x64-14/binding.node ` exists.

testing binary.
Binary is fine; exiting.

can you somebody please help me ? grunt is working fine on my other projects of roots theme. thank you

Seems like you need xcode installed

i fixed with

 node -v && npm -v && gulp -v and 

after install bower. now gulp is working. thanks.