Gulp browser sync ENOENT
Running gulp serves, results in the following error:
[BS] [debug] Getting option: socket.path
[BS] [debug] Getting option: socket.namespace
events.js:72
throw er; // Unhandled 'error' event
^
Error: spawn ENOENT
at errnoException (child_process.js:1001:11)
at Process.ChildProcess._handle.onexit (child_process.js:792:34)
Only appears when starting browser-sync, here's my sync-sync config:
browserSync({
notify: false,
server: {
baseDir: ['app']
},
watchOptions: {
debounceDelay: 250
},
startPath: "/" + view + ".html",
injectChanges: true,
logLevel: "debug",
browser: ["google chrome"]
});
I am running the following versions:
node: 0.10.33 gulp: 3.8.10 browser-sync: 1.8.2 (tried 1.9.x too)
The startup path is correct and exists, disabling ghostMode does not help.
+3
source to share
4 answers
I found this comment to provide the best fit:
browser: process.platform === 'darwin' ? 'MAC_OS_X_SPECIFIC_BROWSER' : 'OTHER'
0
source to share
browser: "google-chrome" is the correct config. When configuring BrowerSync, use "google-chrome" with a dash instead of "google chrome" or "chrome". So your config should look like this:
browserSync({
notify: false,
server: { baseDir: ['app'] },
watchOptions: { debounceDelay: 250 },
startPath: "/" + view + ".html",
injectChanges: true,
logLevel: "debug",
browser: "google-chrome"
});
-2
source to share