Package Exports
- @xyfir/annotate-cli
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@xyfir/annotate-cli) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Formerly known as auto-annotator, annotate-cli is a command line tool that allows you to, among other things, automatically generate annotations for an entire library of ebooks via xyAnnotations. This tool is compatible with Calibre and xyBooks libraries.
annotate-cli offers a lot more than the basic, common use-case described below. See the docs for more information.
Install
npm install -g @xyfir/annotate-clior you can clone this repo and then:
cd path/to/annotate/cli
npm install -gConfiguration
Before generating annotations, there's a few things you must do first:
- Generate an access key for your Xyfir Annotations account and save it to annotate-cli's config.
- Go to Xyfir Annotations access keys section.
- Generate a new key, and copy that key.
- Run the following command:
annotate config --key xyfirAnnotationsAccessKey --value "ACCESS_KEY".ACCESS_KEYshould be replaced with the key you copied.
- Save your Calibre ebook library path to config.
- Find your library directory. This is wherever Calibre stores your books and settings for the library you wish to generate annotations for. The path you're looking for contains a
metadata.dbfile and folders with author names. - If your library is in Xyfir Books, you will need to download the entire library locally, and then make sure you have Calibre installed.
- Run the following command:
annotate config --key calibreLibraryPath --value "LIBRARY_PATH".LIBRARY_PATHshould be replaced with the path.
- Find your library directory. This is wherever Calibre stores your books and settings for the library you wish to generate annotations for. The path you're looking for contains a
- Save Calibre's binary directory path to config.
- You can skip this step if you know that Calibre's binary directory is added to your
PATH. - Find the path. On Windows, where this setting is most likely needed, it should be located at
C:\Program Files\Calibre2. Look for files likecalibredb,ebook-convert, etc. - Run the following command:
annotate config --key calibreBinPath --value "BIN_PATH".BIN_PATHshould be replaced with the path.
- You can skip this step if you know that Calibre's binary directory is added to your
Now, there's more configuration you can do, but this is the bare minimum to get annotate-cli up and running. See here for more configuration options.
Generating Annotations
annotate generate calibreIf everything is set properly, this will generate annotations for every book not in the ignore list.