diff --git a/gulpfile.js b/gulpfile.js index 0925af6e4c..d4405a9a34 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -97,9 +97,19 @@ function process_package_debug(done) { getGitRevision(done, processPackage, false); } -// dist_yarn MUST be done after dist_src - -const distCommon = gulp.series(dist_src, dist_less, dist_changelog, dist_yarn, dist_locale, dist_libraries, dist_resources, dist_rollup, gulp.series(cordova_dist())); +const distCommon = gulp.series( + dist_src, + dist_node_modules_css, + dist_less, + dist_changelog, + dist_locale, + dist_libraries, + dist_resources, + dist_rollup, + gulp.series( + cordova_dist(), + ), +); const distBuild = gulp.series(process_package_release, distCommon); @@ -344,9 +354,12 @@ function processPackage(done, gitRevision, isReleaseBuild) { function dist_src() { const distSources = [ './src/**/*', + '!./src/**/*.js', + '!./src/**/*.vue', '!./src/css/dropdown-lists/LICENSE', '!./src/support/**', '!./src/**/*.less', + './src/js/workers/hex_parser.js', ]; return gulp.src(distSources, { base: 'src' }) @@ -354,12 +367,17 @@ function dist_src() { .pipe(gulp.dest(DIST_DIR)); } +function dist_node_modules_css() { + return gulp.src('./**/*.min.css') + .pipe(gulp.dest(DIST_DIR)); +} + function dist_less() { return gulp.src('./src/**/*.less') .pipe(sourcemaps.init()) .pipe(less()) .pipe(sourcemaps.write('.')) - .pipe(gulp.dest(`${DIST_DIR}`)); + .pipe(gulp.dest(DIST_DIR)); } function dist_changelog() { @@ -367,15 +385,6 @@ function dist_changelog() { .pipe(gulp.dest(`${DIST_DIR}tabs/`)); } -// This function relies on files from the dist_src function -function dist_yarn() { - return gulp.src([`${DIST_DIR}package.json`, `${DIST_DIR}yarn.lock`]) - .pipe(gulp.dest(DIST_DIR)) - .pipe(yarn({ - production: true, - })); -} - function dist_locale() { return gulp.src('./locales/**/*', { base: 'locales'}) .pipe(gulp.dest(`${DIST_DIR}locales`)); @@ -400,6 +409,7 @@ function dist_rollup() { return rollup .rollup({ + strictDeprecations: true, input: { // For any new file migrated to modules add the output path // in dist on the left, on the right it's input file path. @@ -441,7 +451,6 @@ function dist_rollup() { // we want to see code in the same way as it // is in the source files while debugging sourcemap: true, - // put any 3rd party module in vendor.js manualChunks(id) { /** * This splits every npm module loaded in into it's own package diff --git a/package.json b/package.json index 9350de4be4..7bd8168370 100644 --- a/package.json +++ b/package.json @@ -122,7 +122,7 @@ "nw-builder": "3.8.3", "os": "^0.1.2", "postcss": "^8.4.31", - "rollup": "^3.9.0", + "rollup": "^3.29.4", "rollup-plugin-copy": "^3.5.0", "rollup-plugin-vue": "^5.*.*", "rpm-builder": "^1.2.1", diff --git a/yarn.lock b/yarn.lock index b614bece99..8dae632272 100644 --- a/yarn.lock +++ b/yarn.lock @@ -13263,13 +13263,20 @@ rollup-pluginutils@^2.8.2: dependencies: estree-walker "^0.6.1" -rollup@^3.27.1, rollup@^3.9.0: +rollup@^3.27.1: version "3.29.0" resolved "https://registry.yarnpkg.com/rollup/-/rollup-3.29.0.tgz#1b40e64818afc979c7e5bef93de675829288986b" integrity sha512-nszM8DINnx1vSS+TpbWKMkxem0CDWk3cSit/WWCBVs9/JZ1I/XLwOsiUglYuYReaeWWSsW9kge5zE5NZtf/a4w== optionalDependencies: fsevents "~2.3.2" +rollup@^3.29.4: + version "3.29.4" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-3.29.4.tgz#4d70c0f9834146df8705bfb69a9a19c9e1109981" + integrity sha512-oWzmBZwvYrU0iJHtDmhsm662rC15FRXmcjCk1xD771dFDx5jJ02ufAQQTn0etB2emNk4J9EZg/yWKpsn9BWGRw== + optionalDependencies: + fsevents "~2.3.2" + rpm-builder@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/rpm-builder/-/rpm-builder-1.2.1.tgz#94655088266ec213f474efec0a9d9034404d0331"