Skip to main content

Ad removal tool for PDFs.

Project description

Gulag Cleaner

Twitter Instagram Ko-fi

Gulag Cleaner is a tool designed to remove advertisements from PDFs, making it easier to read and navigate documents without being disrupted by unwanted ads.

This tool does not just crop the ads out of the PDF, instead, we extract the original file without ads by manipulating the internal structure of the PDF, ensuring maximum quality.

In addition to removing advertisements, Gulag Cleaner is also capable of extracting metadata, such as the author, subject, university, and more, from the file.

Web Version

This tool can be used without installation directly from our website (in Spanish).

Gulag Cleaner webpage

Installation

To install Gulag Cleaner, please download and install Python and then run the following command in your terminal:

pip install gulagcleaner

Usage

Gulag Cleaner can be used through both a Command Line Interface (CLI) and in your code.

Command Line Interface

To use Gulag Cleaner through the CLI, simply run the following command, replacing <filename> with the name of one or more PDF files or folders containing PDF:

gulagcleaner [-r] [-s] [-n] [-h] [-v] <filename>...

Options

Gulag Cleaner provides several options for its usage:

  • '-r': Replace the original file with the cleaned version.
  • '-s': Do not show metadata about cleaned files.
  • '-n': Force the naive cleaning method.
  • '-h': Display the help message, providing information on how to use Gulag Cleaner.
  • '-v': Display the current version of Gulag Cleaner.

Code

To use Gulag Cleaner in your code, you can use the following code snippet:

from gulagcleaner.extract import clean_pdf

return_msg = clean_pdf_path("input.pdf","output.pdf")

License

Gulag Cleaner is distributed under the GPL-3 license, which means it's open-source and free to use.

Contributing

We're always looking for ways to improve Gulag Cleaner, and we welcome contributions from the community. If you have ideas for improvements or bug fixes, please feel free to submit a pull request.

TODO

If you want to help, these are the top priorities right now:

  • Write tests for the package.
  • Add README.md (With code examples) for the rust and JS distributions.
  • Add comments to a lot of the rust code.
  • Optimize the rust code for performance improvements.
  • Add a new "clean_pdf_bytes()" function in python that does not require a file path, just the bytes.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

gulagcleaner-0.12.1-cp312-cp312-win_amd64.whl (382.6 kB view hashes)

Uploaded CPython 3.12 Windows x86-64

gulagcleaner-0.12.1-cp312-cp312-win32.whl (367.9 kB view hashes)

Uploaded CPython 3.12 Windows x86

gulagcleaner-0.12.1-cp312-cp312-musllinux_1_1_x86_64.whl (1.3 MB view hashes)

Uploaded CPython 3.12 musllinux: musl 1.1+ x86-64

gulagcleaner-0.12.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.3 MB view hashes)

Uploaded CPython 3.12 manylinux: glibc 2.17+ x86-64

gulagcleaner-0.12.1-cp312-cp312-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl (1.4 MB view hashes)

Uploaded CPython 3.12 manylinux: glibc 2.12+ i686 manylinux: glibc 2.17+ i686

gulagcleaner-0.12.1-cp312-cp312-macosx_10_9_x86_64.whl (515.5 kB view hashes)

Uploaded CPython 3.12 macOS 10.9+ x86-64

gulagcleaner-0.12.1-cp311-cp311-win_amd64.whl (382.7 kB view hashes)

Uploaded CPython 3.11 Windows x86-64

gulagcleaner-0.12.1-cp311-cp311-win32.whl (368.3 kB view hashes)

Uploaded CPython 3.11 Windows x86

gulagcleaner-0.12.1-cp311-cp311-musllinux_1_1_x86_64.whl (1.3 MB view hashes)

Uploaded CPython 3.11 musllinux: musl 1.1+ x86-64

gulagcleaner-0.12.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.3 MB view hashes)

Uploaded CPython 3.11 manylinux: glibc 2.17+ x86-64

gulagcleaner-0.12.1-cp311-cp311-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl (1.4 MB view hashes)

Uploaded CPython 3.11 manylinux: glibc 2.12+ i686 manylinux: glibc 2.17+ i686

gulagcleaner-0.12.1-cp311-cp311-macosx_10_9_x86_64.whl (515.9 kB view hashes)

Uploaded CPython 3.11 macOS 10.9+ x86-64

gulagcleaner-0.12.1-cp310-cp310-win_amd64.whl (382.7 kB view hashes)

Uploaded CPython 3.10 Windows x86-64

gulagcleaner-0.12.1-cp310-cp310-win32.whl (368.3 kB view hashes)

Uploaded CPython 3.10 Windows x86

gulagcleaner-0.12.1-cp310-cp310-musllinux_1_1_x86_64.whl (1.3 MB view hashes)

Uploaded CPython 3.10 musllinux: musl 1.1+ x86-64

gulagcleaner-0.12.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.3 MB view hashes)

Uploaded CPython 3.10 manylinux: glibc 2.17+ x86-64

gulagcleaner-0.12.1-cp310-cp310-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl (1.4 MB view hashes)

Uploaded CPython 3.10 manylinux: glibc 2.12+ i686 manylinux: glibc 2.17+ i686

gulagcleaner-0.12.1-cp310-cp310-macosx_10_9_x86_64.whl (515.9 kB view hashes)

Uploaded CPython 3.10 macOS 10.9+ x86-64

gulagcleaner-0.12.1-cp39-cp39-win_amd64.whl (382.5 kB view hashes)

Uploaded CPython 3.9 Windows x86-64

gulagcleaner-0.12.1-cp39-cp39-win32.whl (368.3 kB view hashes)

Uploaded CPython 3.9 Windows x86

gulagcleaner-0.12.1-cp39-cp39-musllinux_1_1_x86_64.whl (1.3 MB view hashes)

Uploaded CPython 3.9 musllinux: musl 1.1+ x86-64

gulagcleaner-0.12.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.3 MB view hashes)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

gulagcleaner-0.12.1-cp39-cp39-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl (1.4 MB view hashes)

Uploaded CPython 3.9 manylinux: glibc 2.12+ i686 manylinux: glibc 2.17+ i686

gulagcleaner-0.12.1-cp39-cp39-macosx_10_9_x86_64.whl (515.8 kB view hashes)

Uploaded CPython 3.9 macOS 10.9+ x86-64

gulagcleaner-0.12.1-cp38-cp38-win_amd64.whl (382.4 kB view hashes)

Uploaded CPython 3.8 Windows x86-64

gulagcleaner-0.12.1-cp38-cp38-win32.whl (368.2 kB view hashes)

Uploaded CPython 3.8 Windows x86

gulagcleaner-0.12.1-cp38-cp38-musllinux_1_1_x86_64.whl (1.3 MB view hashes)

Uploaded CPython 3.8 musllinux: musl 1.1+ x86-64

gulagcleaner-0.12.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.3 MB view hashes)

Uploaded CPython 3.8 manylinux: glibc 2.17+ x86-64

gulagcleaner-0.12.1-cp38-cp38-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl (1.4 MB view hashes)

Uploaded CPython 3.8 manylinux: glibc 2.12+ i686 manylinux: glibc 2.17+ i686

gulagcleaner-0.12.1-cp38-cp38-macosx_10_9_x86_64.whl (515.7 kB view hashes)

Uploaded CPython 3.8 macOS 10.9+ x86-64

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page