久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

<i id='0ravl'><tr id='0ravl'><dt id='0ravl'><q id='0ravl'><span id='0ravl'><b id='0ravl'><form id='0ravl'><ins id='0ravl'></ins><ul id='0ravl'></ul><sub id='0ravl'></sub></form><legend id='0ravl'></legend><bdo id='0ravl'><pre id='0ravl'><center id='0ravl'></center></pre></bdo></b><th id='0ravl'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='0ravl'><tfoot id='0ravl'></tfoot><dl id='0ravl'><fieldset id='0ravl'></fieldset></dl></div>

  • <legend id='0ravl'><style id='0ravl'><dir id='0ravl'><q id='0ravl'></q></dir></style></legend>
  • <small id='0ravl'></small><noframes id='0ravl'>

      1. <tfoot id='0ravl'></tfoot>
        • <bdo id='0ravl'></bdo><ul id='0ravl'></ul>

        使用 gulp-nodemon &amp; 時(shí)無(wú)法使用 Ctrl+C 停止 G

        Cannot stop Gulp with Ctrl+C when using gulp-nodemon amp; gulp.watch together(使用 gulp-nodemon amp; 時(shí)無(wú)法使用 Ctrl+C 停止 Gulpgulp.watch 一起看)
        <i id='HKcNu'><tr id='HKcNu'><dt id='HKcNu'><q id='HKcNu'><span id='HKcNu'><b id='HKcNu'><form id='HKcNu'><ins id='HKcNu'></ins><ul id='HKcNu'></ul><sub id='HKcNu'></sub></form><legend id='HKcNu'></legend><bdo id='HKcNu'><pre id='HKcNu'><center id='HKcNu'></center></pre></bdo></b><th id='HKcNu'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='HKcNu'><tfoot id='HKcNu'></tfoot><dl id='HKcNu'><fieldset id='HKcNu'></fieldset></dl></div>
        <legend id='HKcNu'><style id='HKcNu'><dir id='HKcNu'><q id='HKcNu'></q></dir></style></legend>

          <bdo id='HKcNu'></bdo><ul id='HKcNu'></ul>

          • <tfoot id='HKcNu'></tfoot>
                  <tbody id='HKcNu'></tbody>

                  <small id='HKcNu'></small><noframes id='HKcNu'>

                  本文介紹了使用 gulp-nodemon &amp; 時(shí)無(wú)法使用 Ctrl+C 停止 Gulpgulp.watch 一起看的處理方法,對(duì)大家解決問(wèn)題具有一定的參考價(jià)值,需要的朋友們下面隨著小編來(lái)一起學(xué)習(xí)吧!

                  問(wèn)題描述

                  限時(shí)送ChatGPT賬號(hào)..

                  當(dāng)我在沒(méi)有 node 任務(wù)的情況下運(yùn)行 gulp 時(shí),它可以正常工作并按預(yù)期處理客戶端文件,如果我運(yùn)行 gulp node 它會(huì)按預(yù)期處理服務(wù)器文件.但是,如果我同時(shí)運(yùn)行 gulp 它會(huì)按預(yù)期同時(shí)處理客戶端和服務(wù)器文件,但是,它不會(huì)讓我通過(guò)按Ctrl + C"退出(在 Windows 10 和 Mac El Capitan 上嘗試過(guò))).我在這里做錯(cuò)了嗎?

                  When I run gulp without the node task, it works fine and processes client file as expected, If I run gulp node it processes server file as expected. However if I run both gulp it processes both client and server file as expected, however, it won't let me quit by pressing 'Ctrl + C' (Tried it on windows 10 & Mac El Capitan). Is there something I'm doing wrong here?

                  'use strict';
                    var gulp = require('gulp');
                      var connect = require('gulp-connect'); 
                      var browserify = require('browserify'); 
                      var source = require('vinyl-source-stream'); 
                      var nodemon = require('gulp-nodemon');
                  
                      var config = {
                          port: 9005,
                          devBaseUrl: 'http://localhost',
                          paths: {
                              html: './src/*.html',
                              dist: './dist',
                              js: './src/**/*.js',
                              images: './src/images/*',
                              mainJs: './src/main.js',
                              css: [
                                  'node_modules/bootstrap/dist/css/bootstrap.min.css',
                                  'node_modules/bootstrap/dist/css/bootstrap-theme.min.css'
                              ]
                          }
                      };
                  
                  gulp.task('connect', function () {
                      connect.server({
                          root: ['dist'],
                          port: config.port,
                          base: config.devBaseUrl,
                          livereload: true
                      });
                  });
                  
                  
                  gulp.task('html', function () {
                      gulp.src(config.paths.html)
                          .pipe(gulp.dest(config.paths.dist))
                  });
                  
                  gulp.task('js', function () {
                      browserify(config.paths.mainJs)
                          .bundle()
                          .on('error', console.error.bind(console))
                          .pipe(source('bundle.js'))
                          .pipe(gulp.dest(config.paths.dist + '/scripts'))
                          .pipe(connect.reload())
                  
                  });
                  
                  gulp.task('node', function () {
                      nodemon({
                          script: 'server/index.js',
                          ext: 'js',
                          env: {
                              PORT: 8000
                          },
                          ignore: ['node_modules/**','src/**','dist/**']
                      })
                      .on('restart', function () {
                          console.log('Restarting node server...');
                      })
                  });
                  
                  gulp.task('watch', function () {
                      gulp.watch(config.paths.js, ['js']);
                  });
                  
                  gulp.task('default', ['html', 'js', 'connect', 'node', 'watch']);
                  

                  推薦答案

                  我之前遇到過(guò)類(lèi)似的問(wèn)題,這就是您要找的:

                  I had a similar issue before this is what you're looking for :

                  process.on('SIGINT', function() {
                    setTimeout(function() {
                      gutil.log(gutil.colors.red('Successfully closed ' + process.pid));
                      process.exit(1);
                    }, 500);
                  });
                  

                  只需將此代碼添加到您的 gulp 文件中即可.它將監(jiān)視 ctrl + C 并正確終止該過(guò)程.如果需要,您也可以在超時(shí)中添加一些其他代碼.

                  Just add this code to your gulp file. It will watch the ctrl + C and properly terminate the process. You can put some other code in the timeout also if desired.

                  這篇關(guān)于使用 gulp-nodemon &amp; 時(shí)無(wú)法使用 Ctrl+C 停止 Gulpgulp.watch 一起看的文章就介紹到這了,希望我們推薦的答案對(duì)大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

                  【網(wǎng)站聲明】本站部分內(nèi)容來(lái)源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問(wèn)題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請(qǐng)聯(lián)系我們刪除處理,感謝您的支持!

                  相關(guān)文檔推薦

                  Browserify, Babel 6, Gulp - Unexpected token on spread operator(Browserify,Babel 6,Gulp - 傳播運(yùn)算符上的意外令牌)
                  Is it possible to pass a flag to Gulp to have it run tasks in different ways?(是否可以將標(biāo)志傳遞給 Gulp 以使其以不同的方式運(yùn)行任務(wù)?)
                  Why do we need to install gulp globally and locally?(為什么我們需要在全局和本地安裝 gulp?)
                  How to run Gulp tasks sequentially one after the other(如何一個(gè)接一個(gè)地依次運(yùn)行 Gulp 任務(wù))
                  Stylesheet not loaded because of MIME-type(由于 MIME 類(lèi)型而未加載樣式表)
                  Visual Studio 2015 crashes when opening Javascript files(打開(kāi) Javascript 文件時(shí) Visual Studio 2015 崩潰)
                    <legend id='e7dWm'><style id='e7dWm'><dir id='e7dWm'><q id='e7dWm'></q></dir></style></legend>
                    • <i id='e7dWm'><tr id='e7dWm'><dt id='e7dWm'><q id='e7dWm'><span id='e7dWm'><b id='e7dWm'><form id='e7dWm'><ins id='e7dWm'></ins><ul id='e7dWm'></ul><sub id='e7dWm'></sub></form><legend id='e7dWm'></legend><bdo id='e7dWm'><pre id='e7dWm'><center id='e7dWm'></center></pre></bdo></b><th id='e7dWm'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='e7dWm'><tfoot id='e7dWm'></tfoot><dl id='e7dWm'><fieldset id='e7dWm'></fieldset></dl></div>
                      • <bdo id='e7dWm'></bdo><ul id='e7dWm'></ul>
                            <tbody id='e7dWm'></tbody>

                        1. <tfoot id='e7dWm'></tfoot>

                          <small id='e7dWm'></small><noframes id='e7dWm'>

                            主站蜘蛛池模板: 午夜免费| 亚洲精选一区 | 一区二区三区av夏目彩春 | 日韩电影中文字幕 | 国产精品明星裸体写真集 | 狠狠操狠狠色 | 天天操天天射综合网 | 国产一级一片免费播放 | 亚洲综合国产精品 | 免费在线毛片 | 欧美精品在线一区二区三区 | 国产一区二区在线免费视频 | 九色网址 | 免费视频一区 | 成人欧美一区二区三区1314 | 毛片av免费在线观看 | 久久久久亚洲视频 | www.激情.com | 亚洲一区日韩 | 国产丝袜一区二区三区免费视频 | 99久久中文字幕三级久久日本 | 99pao成人国产永久免费视频 | 狠狠操狠狠干 | 亚洲一区二区免费 | 中文字幕在线观看第一页 | 天天曰天天干 | 国产一区不卡 | 久久天天躁狠狠躁夜夜躁2014 | 国产精品视频一区二区三区 | 在线三级电影 | 亚洲www啪成人一区二区麻豆 | 三级在线视频 | 黄色在线免费观看 | 一区二区在线 | 在线观看国产三级 | 最新国产在线 | 丁香婷婷成人 | 91超碰在线 | 免费观看一级特黄欧美大片 | 日韩日韩日韩日韩日韩日韩日韩 | 青青草av网站 |