Skip to content

Commit

Permalink
v1.22.3
Browse files Browse the repository at this point in the history
### Bug Fixes
- Fixed a memory leak in the Theme that occurred when the `grunt watch` task was used. Builds kicked off by the `watch` would retain a significant chunk of their allocated memory, even after completion. This behavior was corrected. (#906)
  • Loading branch information
tmeyer2115 authored Aug 10, 2021
2 parents fcb4236 + 35be71f commit 71f9d21
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 29 deletions.
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "answers-hitchhiker-theme",
"version": "1.22.2",
"version": "1.22.3",
"description": "A starter answers theme for hitchhikers",
"scripts": {
"test": "cross-env NODE_ICU_DATA=node_modules/full-icu jest --verbose",
Expand Down
32 changes: 7 additions & 25 deletions static/Gruntfile.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const webpackConfig = require('./webpack-config');
const { exec } = require("child_process");
const { spawnSync } = require('child_process');
const jamboConfig = require('./jambo.json');

const outputDir = jamboConfig.dirs.output;
Expand All @@ -12,34 +12,16 @@ module.exports = function (grunt) {
watch: {
all: {
files: ['**', '!**/node_modules/**', `!${outputDir}/**`],
tasks: ['jambobuild', 'webpack',],
options: {
spawn: false,
},
tasks: ['build-site']
},
},
});

grunt.loadNpmTasks('grunt-webpack');
grunt.loadNpmTasks('grunt-contrib-watch');

grunt.registerTask('jambobuild', 'Jambo build.',
function() {
// Force task into async mode and grab a handle to the "done" function.
var done = this.async();
// Run some sync stuff.
grunt.log.writeln('Processing task...');
// And some async stuff.
exec('npx jambo build', (error, stdout, stderr) => {
if (error) {
console.log(error.message);
done(false);
return;
}

stderr && console.error(stderr);
stdout && console.log(stdout);
done();
grunt.registerTask('build-site', 'Builds the site.', () => {
spawnSync('npx jambo build && npx webpack --config webpack-config.js', {
shell: true,
stdio: 'inherit'
});
});
}
}
2 changes: 1 addition & 1 deletion static/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion static/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "answers-hitchhiker-theme",
"version": "1.22.2",
"version": "1.22.3",
"description": "Toolchain for use with the HH Theme",
"main": "Gruntfile.js",
"scripts": {
Expand Down

0 comments on commit 71f9d21

Please sign in to comment.