This project exports your local Zotero library to a usable HTML website.
Project description
Zotsite: A Zotero Export Utility
This project exports your local Zotero library to a usable HTML website. This generated website has the following features:
- Easily access your papers, site snapshots, notes from a navigation tree.
- Provides metadata from collections and attachments (i.e. referenes etc).
- Display PDF papers and website snapshot (the latter as framed).
- Search function dynamically narrows down the papers you're looking for.
- Embed links to a specific collection, article, item, note etc.
- Export only a portion of your collection with regular expressions using the collection name.
- BetterBibtex integration.
- Snazzy look and feel from the latest Bootstrap CSS/Javascript library.
Documentation
See the full documentation.
Obtaining
The easist way to install the command line program is via the pip
installer:
pip3 install zensols.zotsite
Binaries are also available on pypi.
Process
The tool does the following:
- Exports the meta data (directory structure, references, notes, etc) from your Zotero library. On MacOS, this is done by querying the file system SQLite DB files.
- Copies a static site that enables traversal of the exported data.
- Copies your Zotero stored papers, snapshot (sites) etc.
- Generates a navigation tree to easily find your papers/content.
Sample Site Demonstration
See the live demo, which provides a variety of resources found in my own library. Note: To my knowledge, all of these resources are free to distribute and violate no laws. If I've missed one, please create an issue.
Requirements
BetterBibtex plugin for Zotero.
Usage
The command line program has two modes: show configuration (a good first step) and to create the web site. You can see what the program is parsing from your Zotero library:
zotsite print
To create the stand-alone site, run the program (without the angle brackets):
zotsite export
If your library is not in the default $HOME/zotero directory you will need to change that path by making a zotsite.conf config file:
zotsite export -c zotsite.conf
This will create the html files in the directory ./zotsite
See usage for more information.
Configuration File
Either an environment variable ZOTSITERC
must be set or a -c
configuration
option must be given and point to a file to customize how the program works.
See the test configuration file for an example and inline comments for more
detail on how and what can be configured.
Ubuntu and Linux Systems with Python 3.5 or Previous Version
Please read this issue if you are installing a Ubuntu or any Linux system with Python 3.5 or previous version.
Command Line Help
Command line usage as provided with the --help
option:
Usage: zotsite [list|export|print] [options]:
This project exports your local Zotero library to a usable HTML website.
Options:
-h, --help show this help message and exit
--version show the program version and exit
--level X the level to set the application logger,
X is one of: debug, err, info, warn
-c, --config FILE the path to the configuration file
Actions:
list list all actions and help
--lstfmt <json|name|text> text the output format for the action listing
export (default) generate and export the zotero website
--collection REGEX a regular expression used to filter "collection" nodes
-o, --outputdir DIR the directory to dump the site; default to configuration file
print print (sub)collections and papers in those collections as a tree
--collection REGEX a regular expression used to filter "collection" nodes
Attribution
This software uses:
- Python 3
- jQuery version 3
- DataTables version 1.12
- Bootstrap version 4
- Tree View for Bootstrap
- Popper for tooltips
- Copy to Clipboard function
Screenshot
Also see the live demo.
Todo
- Make the site portion a proper Javascript site. Right now, all the
min
s are added in the distribution to same directory as the main navigation/content file. - Add functionality to the disabled View button that drills down in a paper and finds a PDF or site to view withouth the user having to do this.
- Use something like zotxt to make this work with a plugin rather than directly against the SQLite DB.
Zotero Plugin Listing
This is listed as a plugin on the Zotero site.
Changelog
An extensive changelog is available here.
License
Copyright (c) 2019 - 2022 Paul Landes
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
File details
Details for the file zensols.zotsite-0.6.2-py3.10.egg
.
File metadata
- Download URL: zensols.zotsite-0.6.2-py3.10.egg
- Upload date:
- Size: 649.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e672fd38b8a0e0054fd91ec299525d60e74e9a2b0207a0644d42a2bbfc742788 |
|
MD5 | d3edce954764f9ea84943a4f03c19e2d |
|
BLAKE2b-256 | 0b000d8515d5bcebb578b3082f1823787923d4c1406d4fdc153bfbda4a027504 |
File details
Details for the file zensols.zotsite-0.6.2-py3-none-any.whl
.
File metadata
- Download URL: zensols.zotsite-0.6.2-py3-none-any.whl
- Upload date:
- Size: 625.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b0d52418abc5c7ac909c9e519d71345a4ba8039e0ca3109b57aad9d829e5b7da |
|
MD5 | c4a801ef77b3ed121b6611214c1c1066 |
|
BLAKE2b-256 | 1bb261d373004656b2b34b892224f081759150794e14999d3a1d8360b3d258c6 |