Skip to content

Instantly share code, notes, and snippets.

@ringods
Last active June 1, 2016 19:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ringods/5ab7d21b8d7fc20b690485b03495f3a8 to your computer and use it in GitHub Desktop.
Save ringods/5ab7d21b8d7fc20b690485b03495f3a8 to your computer and use it in GitHub Desktop.
binding.read error
> @ images:watch /pipeline/source
> nodemon --watch ./src/images --ext gif,png,jpg -x "npm run images:build" --legacy-watch
fs.js:651
var r = binding.read(fd, buffer, offset, length, position);
^
Error: EBADF: bad file descriptor, read
at Error (native)
at Object.fs.readSync (fs.js:651:19)
at Object.fs.readFileSync (fs.js:467:24)
at Object.Module._extensions..js (module.js:421:20)
at Module.load (module.js:357:32)
at Function.Module._load (module.js:314:12)
at Module.require (module.js:367:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/pipeline/source/node_modules/nodemon/lib/config/index.js:12:15)
at Module._compile (module.js:413:34)
{
"devDependencies": {
"autoprefixer": "^6.3.6",
"browser-sync": "^2.12.10",
"concat-cli": "^4.0.0",
"eslint": "^2.10.2",
"eslint-config-standard": "^5.3.1",
"eslint-plugin-promise": "^1.3.0",
"eslint-plugin-standard": "^1.3.2",
"imagemin-cli": "^2.1.0",
"node-rev": "^1.1.3",
"node-sass": "^3.7.0",
"nodemon": "^1.9.2",
"npm-run-all": "^2.1.1",
"parallelshell": "^2.0.0",
"postcss-cli": "^2.5.2",
"uglify-js": "^2.6.2"
},
"config": {
"postcssPlugins": "require('autoprefixer')(), require('lost')()"
},
"scripts": {
"build:assets": "npm run css:build && npm run js:build && npm run images:build",
"build:master": "npm run build:assets && npm run hugo:build",
"build:develop": "npm run build:assets && npm run hugo:dev",
"clean": "rm -rf ./target",
"css:build": "npm run css:sass && npm run css:concat && npm run css:autoprefixer && npm run css:rev",
"css:sass": "mkdir -p target/tmp/styles/css && node-sass src/styles --recursive --output-style compressed --output target/tmp/styles/css/",
"css:concat": "mkdir -p ./target/tmp/styles/concat && concat-cli -f ./target/tmp/styles/css/*.css -o target/tmp/styles/concat/app.css",
"css:autoprefixer": "postcss -u autoprefixer -r target/tmp/styles/concat/*",
"css:rev": "mkdir -p target/tmp/data && nodeRev 'target/tmp/styles/concat/*.css' --hash -o 'target/dist/styles' --file 'target/tmp/data/styles.json'",
"css:watch": "nodemon --watch ./src/styles --ext scss -x \"npm run css:build\" --legacy-watch",
"hugo:build": "hugo --config=\"src/config.toml\"",
"hugo:dev": "hugo --config=\"src/config-dev.toml\"",
"hugo:watch": "nodemon --watch ./src/content --watch ./src/layouts --ext md,html -x \"npm run hugo:dev\" --legacy-watch",
"images:build": "npm run images:minify",
"images:minify": "imagemin src/images target/dist/images -p",
"images:watch": "nodemon --watch ./src/images --ext gif,png,jpg -x \"npm run images:build\" --legacy-watch",
"js:build": "npm run js:lint && npm run js:minify && npm run js:rev",
"js:minify": "mkdir -p ./target/tmp/scripts && uglifyjs src/scripts/*.js -o target/tmp/scripts/app.js",
"js:rev": "mkdir -p target/tmp/data && mkdir -p target/dist/scripts && nodeRev 'target/tmp/scripts/*.js' --hash -o 'target/dist/scripts' --file 'target/tmp/data/scripts.json'",
"js:lint": "eslint src/scripts",
"js:watch": "nodemon --watch ./src/scripts -x \"npm run js:build\" --legacy-watch",
"serve": "browser-sync start --config build/bs-config.js",
"watch": "npm-run-all --parallel css:watch js:watch images:watch hugo:watch serve",
"start": "npm run watch"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment