Documentation ¶
Index ¶
- Constants
- Variables
- func Backup() error
- func BackupHandler(_ *url.URL) error
- func Cascade() error
- func CascadeHandler(_ *url.URL) error
- func Complete(ids []string, action string) error
- func CompleteHandler(u *url.URL) error
- func Dehydrate(idSet map[string]bool, all, overwrite bool) error
- func DehydrateHandler(u *url.URL) error
- func DownloadLitRes(ids []string) error
- func DownloadLitResHandler(u *url.URL) error
- func Export(ids []string) error
- func ExportHandler(u *url.URL) error
- func GetLitResCovers(ids []string, forceImported bool) error
- func GetLitResCoversHandler(u *url.URL) error
- func GetLitResDetails(ids []string, newOnly, noThrottle bool) error
- func GetLitResDetailsHandler(u *url.URL) error
- func GetLitResMyBooks() error
- func GetLitResMyBooksHandler(u *url.URL) error
- func GetLiveLibCover(id, src string) error
- func GetLiveLibDetails(ids []string, hc *http.Client, newOnly bool) error
- func GetLiveLibDetailsHandler(u *url.URL) error
- func Import() error
- func ImportHandler(_ *url.URL) error
- func IsImported(id string, rxa kvas.ReduxAssets) bool
- func MapLitResToFedorov(id string, lrdx map[string][]string, rdx map[string]map[string][]string)
- func MapLiveLibToFedorov(id string, lrdx map[string][]string, rdx map[string]map[string][]string)
- func PostCompletion(webhookUrl string) error
- func PostCompletionHandler(u *url.URL) error
- func Purge(id string, webhookUrl string, confirm bool) error
- func PurgeHandler(u *url.URL) error
- func ReduceLitResBookDetails(id string, kv kvas.KeyValues) (map[string][]string, error)
- func ReduceLitResBooksDetails(scoreData bool) error
- func ReduceLitResDetailsHandler(u *url.URL) error
- func ReduceLitResMyBooks() error
- func ReduceLitResMyBooksHandler(_ *url.URL) error
- func ReduceLiveLibBookDetails(id string, kv kvas.KeyValues) (map[string][]string, error)
- func Serve(port int, stderr bool) error
- func ServeHandler(u *url.URL) error
- func Sync(webhookUrl string, newOnly, noThrottle bool) error
- func SyncHandler(u *url.URL) error
- func VersionHandler(_ *url.URL) error
Constants ¶
const ( SetComplete = "set" ClearComplete = "clear" )
const ( LitResDataSource = "litres" LiveLibDataSource = "livelib" )
Variables ¶
var (
GitTag string
)
Functions ¶
func BackupHandler ¶ added in v0.1.85
func CascadeHandler ¶ added in v0.2.1
func CompleteHandler ¶ added in v0.1.38
func DehydrateHandler ¶ added in v0.2.26
func DownloadLitRes ¶ added in v0.2.6
func DownloadLitResHandler ¶ added in v0.2.6
func ExportHandler ¶ added in v0.1.68
func GetLitResCovers ¶ added in v0.2.6
func GetLitResCoversHandler ¶ added in v0.2.6
func GetLitResDetails ¶ added in v0.2.6
func GetLitResDetailsHandler ¶ added in v0.2.6
func GetLitResMyBooks ¶ added in v0.2.6
func GetLitResMyBooks() error
func GetLitResMyBooksHandler ¶ added in v0.2.6
func GetLiveLibCover ¶ added in v0.2.6
func GetLiveLibDetails ¶ added in v0.2.6
func GetLiveLibDetailsHandler ¶ added in v0.2.6
func Import ¶ added in v0.1.73
func Import() error
Import adds external media to the library, e.g. DRM-free purchases from elsewhere. To do that you need to provide the following in the input directory: - BEFORE YOU START: book id should be a value that can be parsed into int64
- book media files, e.g. `id.mp4`, `id.epub`, `id.txt` - book cover named `id.jpg` - import.txt with the media metadata
- id - ISBN is recommended or a LiveLib id
- title, ... - as needed
- data-source=litres - if the book (or similar book) is available on LitRes
- > href - e.g. `/book/mihail-shishkin/pismovnik-447855/`
- data-source=livelib - if the book (or similar book) is available on LiveLib
- > id of the book should match LiveLib id, e.g. `1003406901`
- download-links - filenames of the book media files, e.g. id.mp4, id.epub, id.txt
- download-titles - human-readable titles corresponding to the download-links
- > e.g. Audio-book (MP4), EPUB, Text file
Upon placing those files, you can run import command. When import completes - all those input files are removed. import.txt is moved to the _imported subdirectory of the input directory as YYYYMMDD-HHMM-import.txt, where YYYYMMDD-HHMM is the date and time of the import.
If needed you can move YYYYMMDD-HHMM-import.txt back to the input directory, rename to import.txt, change some values and import again. New data will overwrite any existing data.
Another suggestion is to consider exporting the book with similar metadata to use as a base for import.txt. export.txt and import.txt have identical structure.
func ImportHandler ¶ added in v0.1.73
func IsImported ¶ added in v0.1.73
func IsImported(id string, rxa kvas.ReduxAssets) bool
func MapLitResToFedorov ¶ added in v0.2.6
func MapLiveLibToFedorov ¶ added in v0.2.6
func PostCompletion ¶ added in v0.2.11
func PostCompletionHandler ¶ added in v0.2.11
func Purge ¶ added in v0.2.42
Purge will remove all book artefacts from the system: - details - covers - downloads - reductions (must be last to allow downloads to be resolved)
func PurgeHandler ¶ added in v0.2.42
func ReduceLitResBookDetails ¶ added in v0.2.6
func ReduceLitResBooksDetails ¶ added in v0.2.6
func ReduceLitResDetailsHandler ¶ added in v0.2.6
func ReduceLitResMyBooks ¶ added in v0.2.6
func ReduceLitResMyBooks() error
func ReduceLitResMyBooksHandler ¶ added in v0.2.6
func ReduceLiveLibBookDetails ¶ added in v0.2.6
func ServeHandler ¶ added in v0.1.5
func SyncHandler ¶ added in v0.1.5
func VersionHandler ¶ added in v0.1.5
Types ¶
This section is empty.
Source Files ¶
- backup.go
- cascade.go
- complete.go
- dehydrate.go
- download_litres.go
- export.go
- get_litres_covers.go
- get_litres_details.go
- get_litres_my_books.go
- get_livelib_cover.go
- get_livelib_details.go
- import.go
- post_completion.go
- purge.go
- reduce_litres_details.go
- reduce_litres_my_books.go
- reduce_livelib_details.go
- serve.go
- sync.go
- version.go