Added command to generate example HTML file to pick from JS test suite
Change-Id: Ifc3595736cef16eba19014e42e7195d6611ebb38
(cherry picked from commit 754e1c2c8294e91543a37db84ea0f7508cbac55c)
diff --git a/.gitignore b/.gitignore
index 07d17ee..400a37b 100644
--- a/.gitignore
+++ b/.gitignore
@@ -16,6 +16,7 @@
script/hypnotoad.pid
.sass-cache
dev/css
+dev/js/spec/src
templates/announcement.html.ep
templates/custom
lib/Kalamar/Plugin/Announcements.pm
diff --git a/Changes b/Changes
index cf67a7e..2d19511 100755
--- a/Changes
+++ b/Changes
@@ -1,6 +1,8 @@
-0.33 2019-03-18
+0.33 2019-03-28
- Fix problem with serialization and deserialization
of large numerical values (#87).
+ - Added command to generate example HTML file
+ to pick from JS test suite.
WARNING: This requires complete recaching, so run
$ perl script/kalamar chi clear default
diff --git a/Gruntfile.js b/Gruntfile.js
index a6cfb95..2577394 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -155,6 +155,17 @@
spawn: false
}
}
+ },
+ shell: {
+ options: {
+ stderr: false
+ },
+ makeDir: {
+ command : 'mkdir -p ./dev/js/spec/src'
+ },
+ createPage: {
+ command : 'perl script/kalamar get / > ./dev/js/spec/src/page.html'
+ }
}
});
@@ -162,6 +173,7 @@
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-contrib-sass');
grunt.loadNpmTasks('grunt-contrib-copy');
+ grunt.loadNpmTasks('grunt-shell');
grunt.loadNpmTasks('grunt-contrib-uglify-es');
grunt.loadNpmTasks('grunt-contrib-requirejs');
grunt.registerTask('img', ['imagemin','copy']);
@@ -169,6 +181,6 @@
grunt.registerTask('css', ['sass']);
grunt.registerTask(
'default',
- ['requirejs', 'uglify', 'imagemin', 'copy', 'sass']
+ ['requirejs', 'uglify', 'imagemin', 'copy', 'sass','shell:makeDir', 'shell:createPage']
);
};
diff --git a/package.json b/package.json
index 9698fb6..a86ba60 100755
--- a/package.json
+++ b/package.json
@@ -4,7 +4,7 @@
"license": "BSD-2-Clause",
"version": "0.33.1",
"pluginVersion": "0.1",
- "repository" : {
+ "repository": {
"type": "git",
"url": "https://github.com/KorAP/Kalamar.git"
},
@@ -16,6 +16,7 @@
"grunt-contrib-sass": "^1.0.0",
"grunt-contrib-uglify-es": "^3.3.0",
"grunt-contrib-watch": "^1.1.0",
+ "grunt-shell": "^3.0.1",
"imagemin": "^5.3.1",
"optipng-bin": "^4.0.0",
"vinyl-fs": "^3.0.2"