From bdf392093af92da7d8fc4e32b68ff0716700522d Mon Sep 17 00:00:00 2001 From: Markus Heiser Date: Wed, 8 Jan 2020 18:09:36 +0100 Subject: build requirements: add a shell script static analysis tool ShellCheck: https://github.com/koalaman/shellcheck Signed-off-by: Markus Heiser --- docs/admin/buildhosts.rst | 50 ++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 41 insertions(+), 9 deletions(-) (limited to 'docs/admin/buildhosts.rst') diff --git a/docs/admin/buildhosts.rst b/docs/admin/buildhosts.rst index 5260da033..c1582cef2 100644 --- a/docs/admin/buildhosts.rst +++ b/docs/admin/buildhosts.rst @@ -35,8 +35,17 @@ processing additional packages are needed. The XeTeX_ needed not only for PDF creation, its also needed for :ref:`math` when HTML output is build. To be able to do :ref:`sphinx:math-support` without CDNs, the math are rendered -as images (``sphinx.ext.imgmath`` extension). If your docs build (``make -docs``) shows warnings like this:: +as images (``sphinx.ext.imgmath`` extension). + +Here is the extract from the :origin:`docs/conf.py` file, setting math renderer +to ``imgmath``: + +.. literalinclude:: ../conf.py + :language: python + :start-after: # sphinx.ext.imgmath setup + :end-before: # sphinx.ext.imgmath setup END + +If your docs build (``make docs``) shows warnings like this:: WARNING: dot(1) not found, for better output quality install \ graphviz from http://www.graphviz.org @@ -47,8 +56,6 @@ docs``) shows warnings like this:: you need to install additional packages on your build host, to get better HTML output. -.. _system requirements: - .. tabs:: .. group-tab:: Ubuntu / debian @@ -94,10 +101,35 @@ For PDF output you also need: texlive-collection-fontsrecommended texlive-collection-latex \ dejavu-sans-fonts dejavu-serif-fonts dejavu-sans-mono-fonts -.. _system requirements END: +.. _sh lint: -.. literalinclude:: ../conf.py - :language: python - :start-after: # sphinx.ext.imgmath setup - :end-before: # sphinx.ext.imgmath setup END +Lint shell scripts +================== + +.. _ShellCheck: https://github.com/koalaman/shellcheck + +To lint shell scripts, we use ShellCheck_ - A shell script static analysis tool. + +.. SNIP sh lint requirements + +.. tabs:: + + .. group-tab:: Ubuntu / debian + + .. code-block:: sh + + $ sudo apt install shellcheck + + .. group-tab:: Arch Linux + + .. code-block:: sh + + $ sudo pacman -S shellcheck + + .. group-tab:: Fedora / RHEL + + .. code-block:: sh + + $ sudo dnf install ShellCheck +.. SNAP sh lint requirements -- cgit v1.2.3 From eedd63ccd504099836d9f528d02daffa6bc826ad Mon Sep 17 00:00:00 2001 From: Markus Heiser Date: Tue, 4 Feb 2020 16:42:13 +0100 Subject: docs: revision of the installation instructions Signed-off-by: Markus Heiser --- docs/admin/buildhosts.rst | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'docs/admin/buildhosts.rst') diff --git a/docs/admin/buildhosts.rst b/docs/admin/buildhosts.rst index c1582cef2..27784764f 100644 --- a/docs/admin/buildhosts.rst +++ b/docs/admin/buildhosts.rst @@ -4,13 +4,18 @@ Buildhosts ========== +To get best results from build, its recommend to install additional packages +on build hosts. + .. sidebar:: This article needs some work If you have any contribution send us your :pull:`PR <../pulls>`, see :ref:`how to contribute`. -To get best results from build, its recommend to install additional packages -on build hosts. +.. contents:: Contents + :depth: 2 + :local: + :backlinks: entry .. _docs build: -- cgit v1.2.3 From 80f7b658047a3541697ef5ae1aae897817b3f43c Mon Sep 17 00:00:00 2001 From: Markus Heiser Date: Mon, 9 Mar 2020 01:37:26 +0100 Subject: searx.sh: add buildhost cmd, installs OS packages for builds Signed-off-by: Markus Heiser --- docs/admin/buildhosts.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'docs/admin/buildhosts.rst') diff --git a/docs/admin/buildhosts.rst b/docs/admin/buildhosts.rst index 27784764f..a6820aa61 100644 --- a/docs/admin/buildhosts.rst +++ b/docs/admin/buildhosts.rst @@ -104,7 +104,8 @@ For PDF output you also need: $ sudo dnf install \ texlive-collection-fontsrecommended texlive-collection-latex \ - dejavu-sans-fonts dejavu-serif-fonts dejavu-sans-mono-fonts + dejavu-sans-fonts dejavu-serif-fonts dejavu-sans-mono-fonts \ + ImageMagick .. _sh lint: -- cgit v1.2.3 From f27f6c6c5d372b257dfe671ec26eb73f6e12ed28 Mon Sep 17 00:00:00 2001 From: Markus Heiser Date: Tue, 31 Mar 2020 18:25:40 +0200 Subject: docs: use make and uitls/searx.sh in containers Signed-off-by: Markus Heiser --- docs/admin/buildhosts.rst | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) (limited to 'docs/admin/buildhosts.rst') diff --git a/docs/admin/buildhosts.rst b/docs/admin/buildhosts.rst index a6820aa61..04698d8d2 100644 --- a/docs/admin/buildhosts.rst +++ b/docs/admin/buildhosts.rst @@ -4,9 +4,6 @@ Buildhosts ========== -To get best results from build, its recommend to install additional packages -on build hosts. - .. sidebar:: This article needs some work If you have any contribution send us your :pull:`PR <../pulls>`, see @@ -17,6 +14,23 @@ on build hosts. :local: :backlinks: entry +To get best results from build, its recommend to install additional packages +on build hosts (see :ref:`searx.sh`).:: + + sudo -H ./utils/searx.sh buildhost + +This will install packages needed by searx: + +.. include:: ../../build/docs/includes/searx.rst + :start-after: START distro-packages + :end-before: END distro-packages + +and packages needed to build docuemtation and run tests: + +.. include:: ../../build/docs/includes/searx.rst + :start-after: START build-packages + :end-before: END build-packages + .. _docs build: Build docs -- cgit v1.2.3 From 4f7a6c09dd1b799a53a25166b49d23adceccea7d Mon Sep 17 00:00:00 2001 From: Markus Heiser Date: Thu, 18 Jun 2020 18:39:56 +0200 Subject: [fix] buildhosts documentation Signed-off-by: Markus Heiser --- docs/admin/buildhosts.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/admin/buildhosts.rst') diff --git a/docs/admin/buildhosts.rst b/docs/admin/buildhosts.rst index 04698d8d2..b1e787398 100644 --- a/docs/admin/buildhosts.rst +++ b/docs/admin/buildhosts.rst @@ -17,7 +17,7 @@ Buildhosts To get best results from build, its recommend to install additional packages on build hosts (see :ref:`searx.sh`).:: - sudo -H ./utils/searx.sh buildhost + sudo -H ./utils/searx.sh install buildhost This will install packages needed by searx: -- cgit v1.2.3 From bfef2c3b65aea8dd3485e0959e068d460577a841 Mon Sep 17 00:00:00 2001 From: Markus Heiser Date: Thu, 18 Jun 2020 18:52:45 +0200 Subject: [fix] buildprocess of docs in LXC (containers) The $DOCS_BUILD variable (like all BUILD variables) in the lxc environment:: sudo -H ./utils/lxc.sh cmd searx-archlinux make docs is different from running build process in the HOST:: make docs with kernel-include directive we can use the environment variables in the reST documents to address the correct file location of the include. Signed-off-by: Markus Heiser --- docs/admin/buildhosts.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/admin/buildhosts.rst') diff --git a/docs/admin/buildhosts.rst b/docs/admin/buildhosts.rst index b1e787398..a727d25b9 100644 --- a/docs/admin/buildhosts.rst +++ b/docs/admin/buildhosts.rst @@ -21,13 +21,13 @@ on build hosts (see :ref:`searx.sh`).:: This will install packages needed by searx: -.. include:: ../../build/docs/includes/searx.rst +.. kernel-include:: $DOCS_BUILD/includes/searx.rst :start-after: START distro-packages :end-before: END distro-packages and packages needed to build docuemtation and run tests: -.. include:: ../../build/docs/includes/searx.rst +.. kernel-include:: $DOCS_BUILD/includes/searx.rst :start-after: START build-packages :end-before: END build-packages -- cgit v1.2.3