rotdrop / nextcloud-app-pdf-downloader

Recusively convert entire directory trees to PDF and provide the resulting document as download.
Other
3 stars 4 forks source link

Recursive PDF Downloader

Table of Contents

Intro

This is an app for the Nextcloud cloud software. It adds a new menu entry to the actions menu of each folder, archive, or individual file in the files view which lets you download, respectively, entire directories trees, all files in archives, or other individual files, converted and assembled as a single PDF file. Additionally, it adds a tab to the details view where version actions can be performed.

For the PDF generation, the following steps are performed:

The app offers the choice between online and background PDF generation. "Background" means that a job is scheduled, and then runs independently of the web browser frontend. The user will be notified after the job has been completed.

Compatibility

The app currently requires PHP >= 8.0. It should be usable with Nextcloud v23 and probably also with v24.

Working Conversions

Builtin Converters

Custom Converters

Administrators may specify a shell script or program for

On-the-fly Extraction of Archive Files

If enabled by an admin users can choose to enable on-the-fly extraction of archive files.

Security

Implementation

This package relies on wapmorgan/unified-archive as the archive handling backend. Please see over there for a list of supported archive formats and how to support further archive formats.

User Preferences

Page Label and File-Name Templates

The app allows configuring page labels and automatically generated download and destination file names based on a user-configured template. The details can be found in Braced Text Templates.

Overlay Font Selection

Include and Exclude Patterns

Files can be included or excluded by regular expressions and a setting controls whether one or the other regular expression has precedence in case both patterns match. Unfortunately, those patterns cannot (yet) be controlled from the "details" panel.

Archive Files

If enabled by the administrators, users can optionally disable the on-the-fly handling of archive files and also restrict the archive size limit imposed by the admins further.

Conversion of Individual Files

Optionally individual files (as opposed to directory trees and archives) can directly be converted to PDF. The default is to enable this feature. The drawback is that this adds an actions menu entry to each filesystem node, even to PDF files themselves.

Performance

Screenshots

Preferences

Files-List

Details-View

file_list

Other Nextcloud PDF Converters

At least two other apps are also either dedicated to or, respectively, allow for PDF conversion:

Todo, some problems I am aware of