summaryrefslogtreecommitdiff
path: root/debian/patches/clean-gruntfiles
diff options
context:
space:
mode:
Diffstat (limited to 'debian/patches/clean-gruntfiles')
-rw-r--r--debian/patches/clean-gruntfiles52
1 files changed, 31 insertions, 21 deletions
diff --git a/debian/patches/clean-gruntfiles b/debian/patches/clean-gruntfiles
index d1001b7..3395fef 100644
--- a/debian/patches/clean-gruntfiles
+++ b/debian/patches/clean-gruntfiles
@@ -1,25 +1,37 @@
+Author: Johannes Schauer Marin Rodrigues <josch@debian.org>
+Comment: disable all grunt task using unpacked modules
+Forwarded: not-needed
+
--- a/searx/static/themes/oscar/gruntfile.js
+++ b/searx/static/themes/oscar/gruntfile.js
-@@ -81,16 +81,9 @@ module.exports = function(grunt) {
+@@ -103,9 +103,6 @@ module.exports = function(grunt) {
+ production: {
+ options: {
+ paths: ["src/less/pointhi", "src/less/logicodev", "src/less/logicodev-dark", "src/less/bootstrap"],
+- plugins: [
+- new (require('less-plugin-clean-css'))()
+- ],
+ sourceMap: true,
+ sourceMapURL: (name) => { const s = name.split('/'); return s[s.length - 1] + '.map';},
+ outputSourceFiles: false,
+@@ -136,16 +133,12 @@ module.exports = function(grunt) {
}
});
-- grunt.loadNpmTasks('grunt-contrib-uglify');
+- grunt.loadNpmTasks('grunt-contrib-copy');
+ grunt.loadNpmTasks('grunt-contrib-uglify');
- grunt.loadNpmTasks('grunt-contrib-jshint');
- grunt.loadNpmTasks('grunt-contrib-watch');
-- grunt.loadNpmTasks('grunt-contrib-concat');
+ grunt.loadNpmTasks('grunt-contrib-concat');
- grunt.loadNpmTasks('grunt-contrib-less');
-+ grunt.loadNpmTasks('grunt-contrib-uglify', '/usr/lib/nodejs');
-+ grunt.loadNpmTasks('grunt-contrib-concat', '/usr/lib/nodejs');
-
-- grunt.registerTask('test', ['jshint']);
--
-- grunt.registerTask('default', ['jshint', 'concat', 'uglify', 'less']);
--
-- grunt.registerTask('styles', ['less']);
+
+ grunt.registerTask('test', ['jshint']);
+
+- grunt.registerTask('default', ['copy', 'jshint', 'concat', 'uglify', 'less']);
+ grunt.registerTask('default', ['concat', 'uglify']);
- };
+ grunt.registerTask('styles', ['less']);
+
--- a/searx/static/themes/simple/gruntfile.js
+++ b/searx/static/themes/simple/gruntfile.js
@@ -67,12 +67,6 @@ module.exports = function(grunt) {
@@ -32,25 +44,23 @@
- compatibility: '*'
- })
- ],
- banner: '/*! searx | <%= grunt.template.today("dd-mm-yyyy") %> | https://github.com/asciimoo/searx */\n'
+ banner: '/*! searx | <%= grunt.template.today("dd-mm-yyyy") %> | <%= process.env.GIT_URL %> */\n'
},
files: {
-@@ -147,15 +141,8 @@ module.exports = function(grunt) {
+@@ -147,15 +141,11 @@ module.exports = function(grunt) {
}
});
- grunt.loadNpmTasks('grunt-contrib-watch');
-- grunt.loadNpmTasks('grunt-contrib-uglify');
+ grunt.loadNpmTasks('grunt-contrib-uglify');
- grunt.loadNpmTasks('grunt-contrib-jshint');
-- grunt.loadNpmTasks('grunt-contrib-concat');
+ grunt.loadNpmTasks('grunt-contrib-concat');
- grunt.loadNpmTasks('grunt-contrib-less');
-- grunt.loadNpmTasks('grunt-contrib-cssmin');
+ grunt.loadNpmTasks('grunt-contrib-cssmin');
- grunt.loadNpmTasks('grunt-webfont');
-+ grunt.loadNpmTasks('grunt-contrib-uglify', '/usr/lib/nodejs');
-+ grunt.loadNpmTasks('grunt-contrib-concat', '/usr/lib/nodejs');
-- grunt.registerTask('test', ['jshint']);
--
+ grunt.registerTask('test', ['jshint']);
+
- grunt.registerTask('default', ['jshint', 'concat', 'uglify', 'less:development', 'less:production']);
+ grunt.registerTask('default', ['concat', 'uglify']);
};