Update appengine_tasks to include playground dependencies (#4591)

* Update appengine_tasks to include playground dependencies
This commit is contained in:
Sam El-Husseini
2021-01-27 14:36:16 -05:00
committed by GitHub
parent 30f34387ea
commit 628d45357f

View File

@@ -53,6 +53,18 @@ function copyAppengineSrc() {
return gulp.src(appengineSrc).pipe(gulp.dest(demoTmpDir));
}
/**
* Copies playground deps into deploy directory.
*/
function copyPlaygroundDeps() {
const playgroundDeps = [
'./node_modules/@blockly/dev-tools/dist/index.js',
'./node_modules/@blockly/theme-modern/dist/index.js',
'./node_modules/@blockly/block-test/dist/index.js',
];
return gulp.src(playgroundDeps, {base: '.'}).pipe(gulp.dest(demoStaticTmpDir));
}
/**
* Deploys files from tmp directory to appengine to version based on the version
* specified in package.json and then cleans the tmp directory.
@@ -82,6 +94,7 @@ const deployDemos = gulp.series(
prepareDeployDir,
copyStaticSrc,
copyAppengineSrc,
copyPlaygroundDeps,
deployAndClean
);