From 13e452f859fafb1af0de726f67a1ba97de16b0e1 Mon Sep 17 00:00:00 2001 From: Christopher Allen Date: Tue, 4 Oct 2022 16:43:56 +0100 Subject: [PATCH] fix(build): Update GitHub Pages deployment to include built files Modify the updateGithubPages task to run clean and build and then git add build/msg dist/*_compressed.js*, so that they will be included in the deployed pages. This fixes the problem created by the previous^2 commit, wherein the demos relied on built files that were not being deployed to GitHub Pages. --- scripts/gulpfiles/git_tasks.js | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/scripts/gulpfiles/git_tasks.js b/scripts/gulpfiles/git_tasks.js index a4a6f25a3..0f1413350 100644 --- a/scripts/gulpfiles/git_tasks.js +++ b/scripts/gulpfiles/git_tasks.js @@ -98,7 +98,7 @@ function pushRebuildBranch(done) { /** * Update github pages with what is currently in develop. * - * Prerequisite: build. + * Prerequisites (invoked): clean, build. */ const updateGithubPages = gulp.series( function(done) { @@ -109,18 +109,20 @@ const updateGithubPages = gulp.series( done(); }, buildTasks.cleanBuildDir, + packageTasks.cleanReleaseDir, buildTasks.build, - buildTasks.checkin, function(done) { - execSync('git commit -am "Rebuild"', { stdio: 'inherit' }); - execSync('git push ' + upstream_url + ' gh-pages --force', { stdio: 'inherit' }); + execSync('git add build/msg/* dist/*_compressed.js*', {stdio: 'inherit'}); + execSync('git commit -am "Rebuild"', {stdio: 'inherit'}); + execSync('git push ' + upstream_url + ' gh-pages --force', + {stdio: 'inherit'}); done(); } ); module.exports = { // Main sequence targets. Each should invoke any immediate prerequisite(s). - updateGithubPages: gulp.series(packageTasks.package, updateGithubPages), + updateGithubPages, // Manually-invokable targets that invoke prerequisites. createRC,