|
||
---|---|---|
cmake | ||
dist/termcolor | ||
man | ||
src | ||
tests | ||
translations | ||
.clang-format | ||
.clang-tidy | ||
.drone.yml | ||
.editorconfig | ||
.gitignore | ||
AUTHORS | ||
CMakeLists.txt | ||
CODE_OF_CONDUCT.adoc | ||
CONTRIBUTING.adoc | ||
CREDITS | ||
LICENSE | ||
README.adoc | ||
screenshot.png |
epubgrep
epubgrep is a search tool for EPUB e-books. It does not operate on lines, but on whole files. All newlines will be replaced by spaces and HTML will be stripped. This means you can search for text spanning multiple lines and don’t have to worry about HTML tags in the text.
epubgrep is licensed under the AGPL-3.0-only. The bundled Termcolor is licensed under the BSD-3-Clause license.
Usage
See man page for more information.
Install
Gentoo
eselect repository enable guru
echo 'app-text/epubgrep' >> /etc/portage/package.accept_keywords/epubgrep
emaint sync -r guru
emerge -a app-text/epubgrep
From source
Dependencies
-
Tested OS: Linux
-
C++ compiler with C++17 support (tested: GCC 7/10, clang 6/11)
-
CMake (at least: 3.12)
-
Boost (tested: 1.75.0 / 1.65.0)
-
gettext (tested: 0.21 / 0.19)
-
libarchive (tested: 3.5 / 3.2)
-
fmt (tested: 7.0 / 4.0)
-
AsciiDoc (tested: 8.6 / 9.0)
-
Termcolor (tested: 2.0) (If not found, the bundled version is used.)
-
Optional
-
Tests: Catch (tested: 2.13 / 1.10)
-
Install dependencies in Debian or Ubuntu
Or distributions that are derived from Debian or Ubuntu. You will need at least Debian buster or Ubuntu bionic.
apt install build-essential cmake libboost-program-options-dev libboost-locale-dev libboost-regex-dev gettext libarchive-dev libfmt-dev asciidoc
Get sourcecode
Release
Download the current release at schlomp.space.
Development version
git clone https://schlomp.space/tastytea/epubgrep.git
Compile
In a terminal, go to the directory where you unpacked / cloned the source code and then:
mkdir -p build && cd build
cmake ..
cmake --build . -- --jobs=$(nproc --ignore=1)
To install, run make install
. To run the tests, run cd tests && ctest
.
-
-DCMAKE_BUILD_TYPE=Debug
for a debug build. -
-DWITH_TESTS=YES
if you want to compile the tests. -
-DXGETTEXT_CMD=String
The program to use instead ofxgettext
. -
-DFALLBACK_BUNDLED=NO
if you don’t want to fall back on bundled libraries.