Reputation: 722
I'm trying to generate a website scaffold with KeystoneJS. I was able to generate the files.
But starting nodejs with npm start
leads to the following Error:
[10:17:29] Using gulpfile /home/daniel/Projects/keystonetest/gulpfile.js
[10:17:29] Task 'watch:lint' is not in your gulpfile
[10:17:29] Please check the documentation for proper gulpfile formatting
npm ERR! Linux 4.4.0-22-generic
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "start"
npm ERR! node v5.11.1
npm ERR! npm v3.8.6
npm ERR! code ELIFECYCLE
npm ERR! [email protected] start: `gulp`
npm ERR! Exit status 1
I'm new to Gulp. I searched for the Meaning of watch:lint
but did not found something about it. As far as I know the task's looking for changes in my project.
My gulp.js:
var gulp = require('gulp');
var watch = require('gulp-watch');
var shell = require('gulp-shell')
var paths = {
'src':['./models/**/*.js','./routes/**/*.js', 'keystone.js','package.json']
};
gulp.task('runKeystone', shell.task('node keystone.js'));
gulp.task('watch', [
'watch:lint'
]);
gulp.task('default', ['watch', 'runKeystone']);
Also one of the node modules (chokidar/fsevents) was not installed due to missing compatibility to my OS (Ubuntu 16.04). As far as I know it's not needed.
What I've tried:
Any idea what I could try?
Thanks in advance!
Upvotes: 2
Views: 660
Reputation: 3243
I noticed that in the template for gulp the task was changed recently but the package in npm has not been updated. Try editing the gulpfile.js and remove the line (and the previous semicolon):
'watch:lint'
It should work afterwards.
Upvotes: 2
Reputation: 11
I'm just facing this problem right now, and it just seems that both grunt and gulp files are not ready for use.
If you dont need gulp and just want to test Keystone, you can set 'none' in yeoman choice for automation tool, or just use node keystone.js
(or nodemon, if you have it installed) instead of npm start
, to avoid this problem until you will use gulp in a right way.
You could also update the package.json to remove the "scripts" assignment, in order to ask npm start
use node keystone.js
.
Hope it helps
Upvotes: 1