summaryrefslogtreecommitdiff
path: root/debian
diff options
context:
space:
mode:
authorJohannes 'josch' Schauer <josch@debian.org>2020-01-31 07:47:31 +0100
committerJohannes 'josch' Schauer <josch@debian.org>2020-02-01 01:12:00 +0100
commitee96c0270a4fab60b58cccfa7614a84b6ca12f2f (patch)
treede91e5aadae4b7177375b0e04b796ab02fce7689 /debian
parent63b12b364d400008a4235facd3bdb9bc6f39f505 (diff)
split patches
Diffstat (limited to 'debian')
-rw-r--r--debian/patches/beautifyjs55
-rw-r--r--debian/patches/clean-gruntfiles56
-rw-r--r--debian/patches/debian-changes206
-rw-r--r--debian/patches/managesh39
-rw-r--r--debian/patches/series6
-rw-r--r--debian/patches/settingsyml13
-rw-r--r--debian/patches/setuppy27
7 files changed, 195 insertions, 207 deletions
diff --git a/debian/patches/beautifyjs b/debian/patches/beautifyjs
new file mode 100644
index 0000000..9b7ff81
--- /dev/null
+++ b/debian/patches/beautifyjs
@@ -0,0 +1,55 @@
+--- a/searx/static/themes/simple/js/searx_src/autocomplete.js
++++ b/searx/static/themes/simple/js/searx_src/autocomplete.js
+@@ -1,4 +1,51 @@
+-(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.AutoComplete = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
++(function(f){
++ if(typeof exports=== "object" && typeof module !== "undefined") {
++ module.exports = f()
++ } else if(typeof define === "function" && define.amd) {
++ define([], f)
++ }else{
++ var g;
++ if(typeof window !== "undefined") {
++ g = window
++ } else if(typeof global !== "undefined") {
++ g = global
++ } else if(typeof self !== "undefined") {
++ g = self
++ } else {
++ g = this
++ }
++ g.AutoComplete = f()
++ }
++})(function(){
++ var define, module, exports;
++ return (function e(t, n, r){
++ function s(o, u){
++ if(!n[o]){
++ if(!t[o]){
++ var a = typeof require == "function" && require;
++ if(!u && a)
++ return a(o, !0);
++ if(i)
++ return i(o, !0);
++ var f = new Error("Cannot find module '" + o + "'");
++ throw f.code = "MODULE_NOT_FOUND", f
++ }
++ var l = n[o] = {
++ exports:{}
++ };
++ t[o][0].call(l.exports,function(e) {
++ var n = t[o][1][e];
++ return s(n?n:e)
++ }, l, l.exports, e, t, n, r)
++ }
++ return n[o].exports
++ }
++ var i = typeof require == "function" && require;
++ for(var o = 0; o < r.length; o++)
++ s(r[o]);
++ return s
++ })({
++ 1:[function(require, module, exports){
+ /*
+ * @license MIT
+ *
diff --git a/debian/patches/clean-gruntfiles b/debian/patches/clean-gruntfiles
new file mode 100644
index 0000000..d1001b7
--- /dev/null
+++ b/debian/patches/clean-gruntfiles
@@ -0,0 +1,56 @@
+--- a/searx/static/themes/oscar/gruntfile.js
++++ b/searx/static/themes/oscar/gruntfile.js
+@@ -81,16 +81,9 @@ module.exports = function(grunt) {
+ }
+ });
+
+- grunt.loadNpmTasks('grunt-contrib-uglify');
+- grunt.loadNpmTasks('grunt-contrib-jshint');
+- grunt.loadNpmTasks('grunt-contrib-watch');
+- 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('default', ['concat', 'uglify']);
+
+ };
+--- a/searx/static/themes/simple/gruntfile.js
++++ b/searx/static/themes/simple/gruntfile.js
+@@ -67,12 +67,6 @@ module.exports = function(grunt) {
+ production: {
+ options: {
+ paths: ["less"],
+- plugins: [
+- new (require('less-plugin-clean-css'))({
+- advanced: true,
+- compatibility: '*'
+- })
+- ],
+ banner: '/*! searx | <%= grunt.template.today("dd-mm-yyyy") %> | https://github.com/asciimoo/searx */\n'
+ },
+ files: {
+@@ -147,15 +141,8 @@ module.exports = function(grunt) {
+ }
+ });
+
+- grunt.loadNpmTasks('grunt-contrib-watch');
+- grunt.loadNpmTasks('grunt-contrib-uglify');
+- grunt.loadNpmTasks('grunt-contrib-jshint');
+- grunt.loadNpmTasks('grunt-contrib-concat');
+- grunt.loadNpmTasks('grunt-contrib-less');
+- 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('default', ['jshint', 'concat', 'uglify', 'less:development', 'less:production']);
++ grunt.registerTask('default', ['concat', 'uglify']);
+ };
diff --git a/debian/patches/debian-changes b/debian/patches/debian-changes
deleted file mode 100644
index a2ed845..0000000
--- a/debian/patches/debian-changes
+++ /dev/null
@@ -1,206 +0,0 @@
-The Debian packaging of searx is maintained in git, using the merging workflow
-described in dgit-maint-merge(7). There isn't a patch queue that can be
-represented as a quilt series.
-
-A detailed breakdown of the changes is available from their canonical
-representation - git commits in the packaging repository. For example, to see
-the changes made by the Debian maintainer in the first upload of upstream
-version 1.2.3, you could use:
-
- % git clone https://git.dgit.debian.org/searx
- % cd searx
- % git log --oneline 1.2.3..debian/1.2.3-1 -- . ':!debian'
-
-(If you have dgit, use `dgit clone searx`, rather than plain `git clone`.)
-
-A single combined diff, containing all the changes, follows.
---- a/manage.sh
-+++ b/manage.sh
-@@ -115,8 +115,7 @@ tests() {
- #
-
- npm_path_setup() {
-- which npm || (printf 'Error: npm is not found\n'; exit 1)
-- export PATH="$(npm bin)":$PATH
-+ true
- }
-
- npm_packages() {
-@@ -138,7 +137,7 @@ npm_packages() {
- build_style() {
- npm_path_setup
-
-- lessc --clean-css="--s1 --advanced --compatibility=ie9" "$BASE_DIR/searx/static/$1" "$BASE_DIR/searx/static/$2"
-+ lessc -x "$BASE_DIR/searx/static/$1" "$BASE_DIR/searx/static/$2"
- }
-
- styles() {
-@@ -152,8 +151,15 @@ styles() {
- build_style themes/courgette/less/style-rtl.less themes/courgette/css/style-rtl.css
- echo '[!] Building pix-art style'
- build_style themes/pix-art/less/style.less themes/pix-art/css/style.css
-- echo '[!] Building bootstrap style'
-- build_style less/bootstrap/bootstrap.less css/bootstrap.min.css
-+ echo '[!] Building simple style'
-+ build_style themes/simple/less/style.less themes/simple/css/searx.min.css
-+ build_style themes/simple/less/style-rtl.less themes/simple/css/searx-rtl.min.css
-+ echo '[!] Building logicodev'
-+ build_style themes/oscar/less/logicodev/oscar.less themes/oscar/css/logicodev.min.css
-+ echo '[!] Building logicodev-dark'
-+ build_style themes/oscar/less/logicodev-dark/oscar.less themes/oscar/css/logicodev-dark.min.css
-+ echo '[!] Building pointhi'
-+ build_style themes/oscar/less/pointhi/oscar.less themes/oscar/css/pointhi.min.css
- }
-
- grunt_build() {
---- a/searx/settings.yml
-+++ b/searx/settings.yml
-@@ -18,8 +18,8 @@ server:
- http_protocol_version : "1.0" # 1.0 and 1.1 are supported
-
- ui:
-- static_path : "" # Custom static path - leave it blank if you didn't change
-- templates_path : "" # Custom templates path - leave it blank if you didn't change
-+ static_path : "/usr/share/python3-searx/static" # Custom static path - leave it blank if you didn't change
-+ templates_path : "/usr/share/python3-searx/templates" # Custom templates path - leave it blank if you didn't change
- default_theme : oscar # ui theme
- default_locale : "" # Default interface locale - leave blank to detect from browser information or use codes from the 'locales' config section
- theme_args :
---- a/searx/static/themes/oscar/gruntfile.js
-+++ b/searx/static/themes/oscar/gruntfile.js
-@@ -81,16 +81,9 @@ module.exports = function(grunt) {
- }
- });
-
-- grunt.loadNpmTasks('grunt-contrib-uglify');
-- grunt.loadNpmTasks('grunt-contrib-jshint');
-- grunt.loadNpmTasks('grunt-contrib-watch');
-- 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('default', ['concat', 'uglify']);
-
- };
---- a/searx/static/themes/simple/gruntfile.js
-+++ b/searx/static/themes/simple/gruntfile.js
-@@ -67,12 +67,6 @@ module.exports = function(grunt) {
- production: {
- options: {
- paths: ["less"],
-- plugins: [
-- new (require('less-plugin-clean-css'))({
-- advanced: true,
-- compatibility: '*'
-- })
-- ],
- banner: '/*! searx | <%= grunt.template.today("dd-mm-yyyy") %> | https://github.com/asciimoo/searx */\n'
- },
- files: {
-@@ -147,15 +141,8 @@ module.exports = function(grunt) {
- }
- });
-
-- grunt.loadNpmTasks('grunt-contrib-watch');
-- grunt.loadNpmTasks('grunt-contrib-uglify');
-- grunt.loadNpmTasks('grunt-contrib-jshint');
-- grunt.loadNpmTasks('grunt-contrib-concat');
-- grunt.loadNpmTasks('grunt-contrib-less');
-- 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('default', ['jshint', 'concat', 'uglify', 'less:development', 'less:production']);
-+ grunt.registerTask('default', ['concat', 'uglify']);
- };
---- a/searx/static/themes/simple/js/searx_src/autocomplete.js
-+++ b/searx/static/themes/simple/js/searx_src/autocomplete.js
-@@ -1,4 +1,51 @@
--(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.AutoComplete = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
-+(function(f){
-+ if(typeof exports=== "object" && typeof module !== "undefined") {
-+ module.exports = f()
-+ } else if(typeof define === "function" && define.amd) {
-+ define([], f)
-+ }else{
-+ var g;
-+ if(typeof window !== "undefined") {
-+ g = window
-+ } else if(typeof global !== "undefined") {
-+ g = global
-+ } else if(typeof self !== "undefined") {
-+ g = self
-+ } else {
-+ g = this
-+ }
-+ g.AutoComplete = f()
-+ }
-+})(function(){
-+ var define, module, exports;
-+ return (function e(t, n, r){
-+ function s(o, u){
-+ if(!n[o]){
-+ if(!t[o]){
-+ var a = typeof require == "function" && require;
-+ if(!u && a)
-+ return a(o, !0);
-+ if(i)
-+ return i(o, !0);
-+ var f = new Error("Cannot find module '" + o + "'");
-+ throw f.code = "MODULE_NOT_FOUND", f
-+ }
-+ var l = n[o] = {
-+ exports:{}
-+ };
-+ t[o][0].call(l.exports,function(e) {
-+ var n = t[o][1][e];
-+ return s(n?n:e)
-+ }, l, l.exports, e, t, n, r)
-+ }
-+ return n[o].exports
-+ }
-+ var i = typeof require == "function" && require;
-+ for(var o = 0; o < r.length; o++)
-+ s(r[o]);
-+ return s
-+ })({
-+ 1:[function(require, module, exports){
- /*
- * @license MIT
- *
---- a/setup.py
-+++ b/setup.py
-@@ -51,23 +51,9 @@ setup(
- },
- package_data={
- 'searx': [
-- 'settings.yml',
-- '../README.rst',
-- '../requirements.txt',
-- '../requirements-dev.txt',
- 'data/*',
- 'plugins/*/*',
-- 'static/*.*',
-- 'static/*/*.*',
-- 'static/*/*/*.*',
-- 'static/*/*/*/*.*',
-- 'static/*/*/*/*/*.*',
-- 'templates/*/*.*',
-- 'templates/*/*/*.*',
-- 'tests/*',
-- 'tests/*/*',
-- 'tests/*/*/*',
-- 'translations/*/*/*'
-+ 'translations/*/*/*.mo'
- ],
- },
-
diff --git a/debian/patches/managesh b/debian/patches/managesh
new file mode 100644
index 0000000..80d8345
--- /dev/null
+++ b/debian/patches/managesh
@@ -0,0 +1,39 @@
+--- a/manage.sh
++++ b/manage.sh
+@@ -115,8 +115,7 @@ tests() {
+ #
+
+ npm_path_setup() {
+- which npm || (printf 'Error: npm is not found\n'; exit 1)
+- export PATH="$(npm bin)":$PATH
++ true
+ }
+
+ npm_packages() {
+@@ -138,7 +137,7 @@ npm_packages() {
+ build_style() {
+ npm_path_setup
+
+- lessc --clean-css="--s1 --advanced --compatibility=ie9" "$BASE_DIR/searx/static/$1" "$BASE_DIR/searx/static/$2"
++ lessc -x "$BASE_DIR/searx/static/$1" "$BASE_DIR/searx/static/$2"
+ }
+
+ styles() {
+@@ -152,8 +151,15 @@ styles() {
+ build_style themes/courgette/less/style-rtl.less themes/courgette/css/style-rtl.css
+ echo '[!] Building pix-art style'
+ build_style themes/pix-art/less/style.less themes/pix-art/css/style.css
+- echo '[!] Building bootstrap style'
+- build_style less/bootstrap/bootstrap.less css/bootstrap.min.css
++ echo '[!] Building simple style'
++ build_style themes/simple/less/style.less themes/simple/css/searx.min.css
++ build_style themes/simple/less/style-rtl.less themes/simple/css/searx-rtl.min.css
++ echo '[!] Building logicodev'
++ build_style themes/oscar/less/logicodev/oscar.less themes/oscar/css/logicodev.min.css
++ echo '[!] Building logicodev-dark'
++ build_style themes/oscar/less/logicodev-dark/oscar.less themes/oscar/css/logicodev-dark.min.css
++ echo '[!] Building pointhi'
++ build_style themes/oscar/less/pointhi/oscar.less themes/oscar/css/pointhi.min.css
+ }
+
+ grunt_build() {
diff --git a/debian/patches/series b/debian/patches/series
index 7bb8252..15bb9db 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,5 @@
-debian-changes
+beautifyjs
+clean-gruntfiles
+managesh
+settingsyml
+setuppy
diff --git a/debian/patches/settingsyml b/debian/patches/settingsyml
new file mode 100644
index 0000000..ed30dc4
--- /dev/null
+++ b/debian/patches/settingsyml
@@ -0,0 +1,13 @@
+--- a/searx/settings.yml
++++ b/searx/settings.yml
+@@ -18,8 +18,8 @@ server:
+ http_protocol_version : "1.0" # 1.0 and 1.1 are supported
+
+ ui:
+- static_path : "" # Custom static path - leave it blank if you didn't change
+- templates_path : "" # Custom templates path - leave it blank if you didn't change
++ static_path : "/usr/share/python3-searx/static" # Custom static path - leave it blank if you didn't change
++ templates_path : "/usr/share/python3-searx/templates" # Custom templates path - leave it blank if you didn't change
+ default_theme : oscar # ui theme
+ default_locale : "" # Default interface locale - leave blank to detect from browser information or use codes from the 'locales' config section
+ theme_args :
diff --git a/debian/patches/setuppy b/debian/patches/setuppy
new file mode 100644
index 0000000..309ff37
--- /dev/null
+++ b/debian/patches/setuppy
@@ -0,0 +1,27 @@
+--- a/setup.py
++++ b/setup.py
+@@ -51,23 +51,9 @@ setup(
+ },
+ package_data={
+ 'searx': [
+- 'settings.yml',
+- '../README.rst',
+- '../requirements.txt',
+- '../requirements-dev.txt',
+ 'data/*',
+ 'plugins/*/*',
+- 'static/*.*',
+- 'static/*/*.*',
+- 'static/*/*/*.*',
+- 'static/*/*/*/*.*',
+- 'static/*/*/*/*/*.*',
+- 'templates/*/*.*',
+- 'templates/*/*/*.*',
+- 'tests/*',
+- 'tests/*/*',
+- 'tests/*/*/*',
+- 'translations/*/*/*'
++ 'translations/*/*/*.mo'
+ ],
+ },
+