diff options
author | Chi Kei Chan <chikeichan@gmail.com> | 2018-01-18 05:48:16 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-01-18 05:48:16 +0800 |
commit | b80ed2c451fee7b94edea9d1655baa2e908939b9 (patch) | |
tree | e9a67e289f043900a77b1bfb34088ad2e5f83864 /gulpfile.js | |
parent | ccb80594be3000488b7c73f9fd5e56168e0d5042 (diff) | |
parent | aa08d1a09dce7324eaa3b3df568df43f8c55cc63 (diff) | |
download | tangerine-wallet-browser-b80ed2c451fee7b94edea9d1655baa2e908939b9.tar tangerine-wallet-browser-b80ed2c451fee7b94edea9d1655baa2e908939b9.tar.gz tangerine-wallet-browser-b80ed2c451fee7b94edea9d1655baa2e908939b9.tar.bz2 tangerine-wallet-browser-b80ed2c451fee7b94edea9d1655baa2e908939b9.tar.lz tangerine-wallet-browser-b80ed2c451fee7b94edea9d1655baa2e908939b9.tar.xz tangerine-wallet-browser-b80ed2c451fee7b94edea9d1655baa2e908939b9.tar.zst tangerine-wallet-browser-b80ed2c451fee7b94edea9d1655baa2e908939b9.zip |
Merge pull request #3007 from alextsg/uat-master-011618
[NewUI] Merge master into uat branch
Diffstat (limited to 'gulpfile.js')
-rw-r--r-- | gulpfile.js | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/gulpfile.js b/gulpfile.js index d64eff025..26c70080f 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -19,6 +19,8 @@ var manifest = require('./app/manifest.json') var gulpif = require('gulp-if') var replace = require('gulp-replace') var mkdirp = require('mkdirp') +var asyncEach = require('async/each') +var exec = require('child_process').exec var sass = require('gulp-sass') var autoprefixer = require('gulp-autoprefixer') var gulpStylelint = require('gulp-stylelint') @@ -161,6 +163,18 @@ gulp.task('copy:watch', function(){ gulp.watch(['./app/{_locales,images}/*', './app/scripts/chromereload.js', './app/*.{html,json}'], gulp.series('copy')) }) +// record deps + +gulp.task('deps', function (cb) { + exec('npm ls', (err, stdoutOutput, stderrOutput) => { + if (err) return cb(err) + const browsers = ['firefox','chrome','edge','opera'] + asyncEach(browsers, (target, done) => { + fs.writeFile(`./dist/${target}/deps.txt`, stdoutOutput, done) + }, cb) + }) +}) + // lint js gulp.task('lint', function () { @@ -289,7 +303,7 @@ gulp.task('apply-prod-environment', function(done) { gulp.task('dev', gulp.series('build:scss', 'dev:js', 'copy', gulp.parallel('watch:scss', 'copy:watch', 'dev:reload'))) -gulp.task('build', gulp.series('clean', 'build:scss', gulp.parallel('build:js', 'copy'))) +gulp.task('build', gulp.series('clean', 'build:scss', gulp.parallel('build:js', 'copy', 'deps'))) gulp.task('dist', gulp.series('apply-prod-environment', 'build', 'zip')) // task generators |