Skip to content

Not all inline images are stripped out successfully #16

@Firsh

Description

@Firsh

This is a wonderful tool and has saved many gigabytes of storage from Gmail, so thans for that. In terms of consistency, I've caught a few emails that didn't originally have traditional attachments (in Gmail if you drag an image into the body it displays them and they don't show up at the end of the message as files). It has processed many emails that had images like this in them and the re-inserted email contained the 1KB deleted yml notice for this kind of attachment.

However, some emails are processed in a way that:

  • image remains in email body
  • 1KB yml still gets added with a hint that they were removed, but they were not
  • the images were actually downloaded, but remain in the email too
  • this leaves some space savings on the table

I call like this

java -jar GmailAttachmentsExtractor.jar --no-validate --fail-late --unsafe --filename "^(?!.*\.yml$)(?!(?i)deleted).*" -l cleanup "has:attachment -in:drafts"

But will run a few more tests specifically filtering for an email that has this problem.

BTW this "drag image into the body of an email" is the bane of existence of long-running threads where each human reply re-inserts such images again and again, multiplying space consumed. The use of this tool reveals this beautifully as an image could get downloaded many times over (not a fault of the tool).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions