Metadata-Version: 2.1
Name: sotoki
Version: 1.2
Summary: Make zimfile from stackexchange dump
Home-page: http://github.com/kiwix/sotoki
Author: dattaz
Author-email: taz@dattaz.fr
License: GPL
Keywords: kiwix zim stackexchange offline
Platform: Linux
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Requires-Dist: Jinja2 (==2.11.1)
Requires-Dist: lxml (==4.5.0)
Requires-Dist: MarkupSafe (==1.1.1)
Requires-Dist: docopt (==0.6.2)
Requires-Dist: python-slugify (==4.0.0)
Requires-Dist: pydenticon (==0.3.1)
Requires-Dist: beautifulsoup4 (==4.8.2)
Requires-Dist: filemagic (==1.6)
Requires-Dist: mistune (>=2.0.0a2)
Requires-Dist: Pillow (==7.0.0)

# Sotoki

*Stack Overflow to Kiwix*

The goal of this project is to create a suite of tools to create
[zim](https://openzim.org) files required by
[kiwix](https://kiwix.org/) reader to make available [Stack Overflow](https://stackoverflow.com/)
offline (without access to Internet).

[![PyPI](https://img.shields.io/pypi/v/sotoki.svg)](https://pypi.python.org/pypi/sotoki)
[![Docker Build Status](https://img.shields.io/docker/build/openzim/sotoki)](https://hub.docker.com/r/openzim/sotoko)
[![CodeFactor](https://www.codefactor.io/repository/github/openzim/sotoki/badge)](https://www.codefactor.io/repository/github/openzim/sotoki)
[![License: GPL v3](https://img.shields.io/badge/License-GPLv3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0)

## Getting started

The use of btrfs as a file system is recommended (and required for stackoverflow)

Install non python dependencies:
```bash
sudo apt-get install jpegoptim pngquant gifsicle advancecomp python-pip python-virtualenv python-dev libxml2-dev libxslt1-dev libbz2-dev p7zip-full python-pillow gif2apng imagemagick
```

Create a virtual environment for python:
```bash
virtualenv --system-site-packages -p python3 ./
```

Activate the virtual enviroment:
```bash
source ./bin/activate
```

Install this lib:
```bash
pip3 install sotoki
```

Usage:
```bash
sotoki <domain> <publisher> [--directory=<dir>] [--nozim] [--tag-depth=<tag_depth>] [--threads=<threads>] [--zimpath=<zimpath>] [--reset] [--reset-images] [--clean-previous] [--nofulltextindex] [--ignoreoldsite] [--nopic] [--no-userprofile]
```

You can use `sotoki -h` to have more explanation about these options

## Example

```bash
for S in `./list_all.sh` ; do sotoki $S Kiwix --threads=12 --reset --clean-previous --no-userprofile ; done
```

## License

[GPLv3](https://www.gnu.org/licenses/gpl-3.0) or later, see
[LICENSE](LICENSE) for more details.


