简体   繁体   English

我正在尝试运行gulp服务并说“未找到gulpfile”。 我是Nodejs的新手。 我不知道我的吞咽路径是否错误

[英]I'm trying to run gulp serve and says 'No gulpfile found'. I'm new with Nodejs. I don't know if I the gulp path is wrong

I think that maybe the path of gulp is wrong. 我认为也许大吃一惊的道路是错误的。 But i'm not sure. 但是我不确定。

import gulp from 'gulp';
import browserSync from 'browser-sync';
import plumber from 'gulp-plumber';
import sass from 'gulp-sass';
import sourcemaps from 'gulp-sourcemaps';
import autoprefixer from 'gulp-autoprefixer';
import cleanCSS from 'gulp-clean-css';
import browserify from 'browserify';
import babelify from 'babelify';
import source from 'vinyl-source-stream';
import buffer from 'vinyl-buffer';
import jsmin from 'gulp-jsmin';
import imagemin from 'gulp-imagemin';
import wpPot from 'gulp-wp-pot';
import sort from 'gulp-sort';

const reload = browserSync.reload;
reloadFiles = ['./script.js', './style.css', './**/*.php'];
proxyOptions = {
  proxy: 'localhost/dakar/',
  notify: false
   };

gulp.task('server', () => browserSync.init(reloadFiles, proxyOptions));

I expect to run the gulp server, but the output is [12:07:16] No gulpfile found 我希望运行gulp服务器,但输出为[12:07:16]找不到gulpfile

Probably your file name isn't gulpfile.js. 您的文件名可能不是gulpfile.js。

Also look into this thread if the above didn't solve your problem: No gulpfile found 如果以上方法不能解决您的问题,也请查看此线程: 找不到gulpfile

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 我不知道我做错了什么,它不起作用,我正在尝试列出任务清单 - i don't know what i did wrong, it doesn't work, i'm trying to make a task list 我在使用gulp和gulp-livereload的节点中遇到错误 - I'm getting error in node using gulp and gulp-livereload 我无法从属性中提取XML数据,我不知道我做错了什么 - I'm having trouble extracting XML data from attributes and I don't know what I'm doing wrong jQuery无法在html中工作,我不知道自己在做什么错 - jQuery not working in html and I don't know what i'm doing wrong 所以我试图在一个数组中获取我的 axios 响应,但我不知道该怎么做 - So i'm trying to get my axios response in an array and I don't know how to do it 我正在尝试回答 Hackerranks 数据结构问题,但我不知道为什么这个 function 会失败 - I'm trying to answer Hackeranks data structure question and i don't know why this function fails 错误:当我运行gulp命令时,找不到模块“扳手”,出现此错误 - Error: Cannot find module 'wrench', I'm getting this error, when i run gulp command 当我从终端运行 gulp 脚本时,为什么我的 gulpfile.js 没有编译为 scripts.js? - Why is my gulpfile.js is not compiling to scripts.js when I run gulp scripts from the terminal? 我不知道我做错了什么,但是我的带有 js 和 css 的 .html 不会显示必须显示的内容 - I don't know what I'm doing wrong but my .html with js and css won't show what is has to show 我正在尝试使用node.js将文件上传到AWS,但我不知道我的代码出了什么问题 - I'm try to upload file using node.js to aws but i don't know what went wrong with my code
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM