Socket
Socket
Sign inDemoInstall

eml-extractor

Package Overview
Dependencies
0
Maintainers
1
Alerts
File Explorer

Install Socket

Detect and block malicious and high-risk dependencies

Install

    eml-extractor

A CLI tool to extract attachments from .eml files (email messages saved as files)


Maintainers
1

Readme

EML Extractor

EML Extractor is a CLI tool to extract attachments from .eml files (email messages saved as files).

Features

  • Find .eml files (recursively or not) in a selected folder;
  • Select individuals .eml files to extraction;
  • Save all attachments in a single main folder;
  • Organize the attachments by email subject subfolder.

Requirements

Python 3.6+

Installation

$ pip install eml-extractor

Usage

By default, the current working directory is used as the source for .eml files as well as destination for extracted attachments. You can set different optional arguments to change this behavior:

usage: eml-extractor [OPTIONS]

Extracts attachments from .eml files

optional arguments:
  -h, --help            show this help message and exit
  -s PATH, --source PATH
                        the directory containing the .eml files to extract
                        attachments (default: current working directory)
  -r, --recursive       allow recursive search for .eml files under SOURCE
                        directory
  -f FILE [FILE ...], --files FILE [FILE ...]
                        specify an .eml file or a list of .eml files to extract
                        attachments
  -d PATH, --destination PATH
                        the directory to extract attachments to (default:
                        current working directory)

Examples

1. Find all .eml files in current working dir, extract the attachments and save them in the same dir:

$ eml-extractor

The command above is equivalent to:

$ eml-extractor --source . --destination .

2. Set another path for searching .eml files:

$ eml-extractor --source /path/to/eml/files/

3. Allow recursive searching:

$ eml-extractor --source /path/to/eml/files/ --recursive

4. Define manually from which files the attachments will be extracted:

$ eml-extractor --files /path/to/file1.eml /path/to/file2.eml

5. Change the path where to save the extracted attachments:

$ eml-extractor --destination /path/to/extracted/attachments/

License

This project is licensed under the terms of the MIT License.

Keywords

FAQs


Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc