Python library and command-line utilities to handle SciELO PS XML files that runs on python > 3.9.
packtools depends on lxml.
Pip + GitHub (recommended) — check the latest version at GitHub releases and replace the version in the URL accordingly:
$ pip install https://github.com/scieloorg/packtools/archive/refs/tags/4.16.0.zipPip + git (development version):
$ pip install git+https://github.com/scieloorg/packtools.gitSource-code:
$ git clone https://github.com/scieloorg/packtools.git
$ cd packtools
$ python setup.py installInstallation as a web application, where a graphical interface for stylechecker
and an HTML previewer is provided (replace the version in the URL with the latest from GitHub releases):
$ pip install "packtools[webapp] @ https://github.com/scieloorg/packtools/archive/refs/tags/4.16.0.zip"or
pip install -r requirements.txt && pip install -r optional-requirements.txtTo run tests execute:
python setup.py testTo run a specific module of tests, type:
python setup.py test -s tests.test_htmlgeneratorRun tests with tox:
tox
htmlgenerator example.xml --loglevel=error --nochecks --nonetworkIt will generate the result in the same path of the .xml file.
Configuring the application:
| environment variable | default value |
|---|---|
| APP_SETTINGS | packtools.webapp.config.default.ProductionConfig |
$ export APP_SETTINGS=packtools.webapp.config.default.ProductionConfig
$ export FLASK_APP=packtools.webapp.app.py
$ flask runhttp://packtools.readthedocs.org/ (we need help!)
Copyright 2013 SciELO scielo-dev@googlegroups.com. Licensed under the terms of the BSD license. Please see LICENSE in the source code for more information.
https://github.com/scieloorg/packtools/blob/master/LICENSE
https://github.com/scieloorg/packtools/blob/master/HISTORY.md