Skip to content

ebelnikola/compress_pdfs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 

Repository files navigation

Certainly. Here's the revised, more concise description of the script:

This Bash script automates the compression of PDF files in the current directory. It's designed to reduce the file size of PDFs that exceed a specified size, helping to save storage space while maintaining file quality.

The script uses a size threshold to determine which files to compress. Any PDF larger than this threshold will be processed using Ghostscript, a powerful tool for PDF manipulation. The threshold concept allows users to focus on compressing only the larger files that are more likely to benefit from size reduction.

Usage:

  1. Save the script as compress_pdfs.sh and make it executable:

    chmod +x compress_pdfs.sh
  2. Run the script:

    • With default settings (200KB threshold):
      ./compress_pdfs.sh
    • Or specify a custom threshold (e.g., 500KB):
      ./compress_pdfs.sh -t 500

The script provides progress output during operation and preserves original files if compression doesn't reduce size.

Note: Ghostscript must be installed on the system for the script to function.

Both the script and README, as one may guess), were generated by AI. Namely, by claude.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages