gulp-concat

gulp-order : not Ordering properly

独自空忆成欢 提交于 2021-01-27 03:55:32
问题 Gulp newbie here, I downloaded gulp-order for ordering js files when concating *.js because some of my javascript files require jquery to load first. Below are my gulpfile.js that have order,concat,rename & uglify. var date = new Date(); var uniq = date.getTime(); gulp.task('admin-scripts', function() { return gulp.src(['assets/admin/js/*.js','!assets/admin/js/respond.min.js','!assets/admin/js/html5shiv.js']) .pipe(order([ "assets/admin/js/jquery.min.js", 'assets/admin/js/*.js' ])) .pipe

gulp concat after sass

女生的网名这么多〃 提交于 2021-01-21 06:34:49
问题 I would like to take the sass output and concat it to another css regular file. example: animate.css app.scss return gulp.src('app.scss') .pipe(sass({ errLogToConsole: true })) .pipe(concat(['animate.css', OUTPUT_OF_THE_SASS_ABOVE])) .pipe(gulp.dest(paths.public+'css/')) .pipe(rename({ extname: '.min.css' })) .pipe(gulp.dest('css/')) .on('end', done); any ideas how to do it? ******* IDEA maybe is it possible to generate the css file from sass in to a temp location, then concat it with css

Gulp js error notification not showing source of error

拜拜、爱过 提交于 2020-01-07 08:46:10
问题 Everything is setup and working to concatenate and compile my styles and scripts. When an error occurs gulp-notify and gulp-plumber throw the error up as a mac notification and in terminal, and gulp doesn't stop running - which is great :) However, I'm finding that the script errors that are thrown up in terminal are always problems with the compiled file script-dist.js instead of the actual concatenated source file. Error gulp-notify: [JS Error] _PATH_/js/script-dist.js: Unexpected token

Prepend custom strings to JS files while concatenating

匆匆过客 提交于 2020-01-02 10:05:58
问题 I am trying to migrate our build process to gulp from existing custom bash build script. We concatenate several unminified opensource JS files like bootstrap, lazyload, ... and our own JS files. We uglify each JS file (removing their licenses as well) in an order, prepend custom license text to some of them as required and concatenate to create the output JS file. The custom license text are currently kept as strings in the bash script. How to achieve this in gulp without creating

Prepend custom strings to JS files while concatenating

点点圈 提交于 2020-01-02 10:05:47
问题 I am trying to migrate our build process to gulp from existing custom bash build script. We concatenate several unminified opensource JS files like bootstrap, lazyload, ... and our own JS files. We uglify each JS file (removing their licenses as well) in an order, prepend custom license text to some of them as required and concatenate to create the output JS file. The custom license text are currently kept as strings in the bash script. How to achieve this in gulp without creating

CKEditor issue in gulp-concat

烂漫一生 提交于 2019-12-24 21:38:04
问题 In my angularjs application, I'm using angular-ckeditor directive for CKEditor to get user inputs(Description and comments). This is my html code to take description; <div ckeditor="options" ng-model="txtDesc" ng-change="descChange()"></div> and for comments; <div ckeditor="options" ng-model="txtComment"></div> And according to this github article; Note : obviously this plugin expects the presence of AngularJS and CKEditor. This is how I'm referring my JS files; <!-- CK editor --> <script src

How can I use gulp to replace a string in a file?

余生长醉 提交于 2019-12-18 14:04:47
问题 I am using gulp to uglify and make ready my javascript files for production. What I have is this code: var concat = require('gulp-concat'); var del = require('del'); var gulp = require('gulp'); var gzip = require('gulp-gzip'); var less = require('gulp-less'); var minifyCSS = require('gulp-minify-css'); var uglify = require('gulp-uglify'); var js = { src: [ // more files here 'temp/js/app/appConfig.js', 'temp/js/app/appConstant.js', // more files here ], gulp.task('scripts', ['clean-js'],

Gulp and Browserify always giving “dest.write is not a function” error

我的未来我决定 提交于 2019-12-13 07:29:07
问题 I'm trying to utilize Browserify in my Gulp file, but it seems no matter how I set things up, it always throws an error that reads "dest.write is not a function". I originally started with this task using gulp-concat: gulp.task('scripts', function() { return gulp.src(['src/shared/js/one.js', 'src/shared/js/two.js', 'src/shared/js/*.js']) .pipe(browserify() .pipe(concat('main.js')) .pipe(gulp.dest('dist/js')) .pipe(browserSync.stream()); }); When I commented out the browserify() line,

How do I ignore a file using gulp?

久未见 提交于 2019-12-13 04:51:25
问题 I have the following folder and file structure: Vendor bootstrap css -bootstrap.css js -bootstrap.js font-awesome css -font-awesome.css nivo-slider -nivo-slider.css theme -theme.css -theme-animate.css -theme-blog.css -theme-responsive.css -theme-shop.css I am trying to make sure that the css files are added to the stream in this specific order: 1) The bootstrap.css file src/vendor/bootstrap/css/bootstrap.css 2) All of the other css files inside the 'src/vendor/' sub-directories in no

gulp-changed with gulp-concat not working

不打扰是莪最后的温柔 提交于 2019-12-12 05:38:04
问题 I want to compile only the .less files that have changed in order to speed up my debug/coding workflow. Here is my gulp task: gulp.src('core/**/*.less') .pipe(changed('core')) .pipe(less().on('error', handleError)) .pipe(autoprefixer('last 2 version')) .pipe(remember()) .pipe(concat('main.min.css')) .pipe(gulp.dest('core')) .on('end', resolve) .on('error', reject); I used gulp-changed and because it didn't work at first, I tried to use gulp-remember as well, but with no effect. The watch