diff --git a/.gitignore b/.gitignore index 8923a5a9b55..42ddbf86357 100644 --- a/.gitignore +++ b/.gitignore @@ -9,5 +9,5 @@ webfonts/ *.crx *.pem *.zip -releases/ +build/ package-lock.json diff --git a/gulpfile.js b/gulpfile.js index a2a4127db07..d411d7a3b9e 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -12,7 +12,7 @@ const gulp = require('gulp'), del = require('del'); const paths = { - releases: './releases/', + build: './build/', dist: './dist/', libDir: './src/lib/', npmDir: './node_modules/', @@ -21,18 +21,18 @@ const paths = { }; const fontsFilter = [ - '!dist/popup/fonts/*', - 'dist/popup/fonts/Open_Sans*.woff', - 'dist/popup/fonts/fontawesome*.woff' + '!build/popup/fonts/*', + 'build/popup/fonts/Open_Sans*.woff', + 'build/popup/fonts/fontawesome*.woff' ]; function dist(browserName, manifest) { - return gulp.src(paths.dist + '**/*') - .pipe(filter(['**', '!dist/edge/**/*'].concat(fontsFilter))) + return gulp.src(paths.build + '**/*') + .pipe(filter(['**', '!build/edge/**/*'].concat(fontsFilter))) .pipe(gulpif('popup/index.html', replace('__BROWSER__', browserName))) .pipe(gulpif('manifest.json', jeditor(manifest))) .pipe(zip(`dist-${browserName}.zip`)) - .pipe(gulp.dest(paths.releases)); + .pipe(gulp.dest(paths.dist)); } gulp.task('dist', ['dist:firefox', 'dist:chrome', 'dist:opera', 'dist:edge']); @@ -63,12 +63,12 @@ gulp.task('dist:chrome', (cb) => { // Since Edge extensions require makeappx to be run we temporarily store it in a folder. gulp.task('dist:edge', (cb) => { - const edgePath = paths.releases + 'Edge/'; + const edgePath = paths.dist + 'Edge/'; const extensionPath = edgePath + 'Extension/'; - const appxPath = paths.releases + 'dist-edge.appx'; + const appxPath = paths.dist + 'dist-edge.appx'; return del([edgePath, appxPath]) - .then(() => edgeCopyDist(paths.dist + '**/*', extensionPath)) + .then(() => edgeCopyBuild(paths.build + '**/*', extensionPath)) .then(() => edgeCopyAssets('./store/windows/**/*', edgePath)) .then(() => { // makeappx.exe must be in your system's path already @@ -79,7 +79,7 @@ gulp.task('dist:edge', (cb) => { }); }); -function edgeCopyDist(source, dest) { +function edgeCopyBuild(source, dest) { return new Promise((resolve, reject) => { gulp.src(source) .on('error', reject) diff --git a/webpack.common.js b/webpack.common.js index d576131ff62..ef8eca072df 100644 --- a/webpack.common.js +++ b/webpack.common.js @@ -60,7 +60,7 @@ module.exports = { }, plugins: [ new CleanWebpackPlugin([ - path.resolve(__dirname, 'dist/*') + path.resolve(__dirname, 'build/*') ]), new webpack.optimize.CommonsChunkPlugin({ name: 'popup/vendor', @@ -100,6 +100,6 @@ module.exports = { }, output: { filename: '[name].js', - path: path.resolve(__dirname, 'dist') + path: path.resolve(__dirname, 'build') } };