GithubHelp home page GithubHelp logo

didenko / mboxrd Goto Github PK

View Code? Open in Web Editor NEW
19.0 3.0 0.0 33 KB

Split message archived from Google Takeout into individual `.eml` message files

License: BSD 3-Clause "New" or "Revised" License

Go 100.00%
google-takeout mbox mbox-files

mboxrd's Introduction

Purpose

Split email archives downloaded from Google Takeout (Download Your Data) service into individual emails. Based on experimentation it looks like Google uses the mboxrd dialect of mbox format with CRLF lines as discussed at the Wikipedia mbox article

License

The project is licensed under the BSD 3-Clause License - see the LICENSE.txt file included with the package.

Using the mboxrd package

The package provides both libraries and a buildable executable. See the code documentation on using the libraries.

GoDoc

Using the mboxrd_split executable

The executable takes the following parameters:

-dir  <name>     : A directory to put the resulting messages to.
                   The directory must exist before running the program.

-mbox <name>     : An mbox file to process and split into messages.

-email <address> : An email which correspondence to be captured. Only
                   the actual address should be provided.

The program does not preserve unfinished last line of the last message in the archive. In the resulting files all message lines end with CRLF after the processing.

During the processing it creates temporary message files and then moves them into the UTC-timestamped .eml file. If the destination filename is already taken by another message, then the later message does not override it. It is left in the temporary file and the error is printed to stderr.

Also a message stays in a temporary file if the program fails to construct a name for the message file. Some forwarded messages, for example, lack the Date: header.

mboxrd's People

Contributors

didenko avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

mboxrd's Issues

Windows binary

Dear Vlad,
Could you be so kind to generate .exe for the rest of us who are mere Windows users w/o compiler?

Temp file rename fails on Windows

Diagnostic printed:

2015/10/12 20:33:24 Message error: Problem renaming "dir\\_msg_303569788" into
"dir/timestamp_suffix.eml", the file may have either of the names. Error: rename
dir\_msg_303569788 dir/timestamp_suffix.eml: The process cannot access the file
because it is being used by another process.

Allow for multiple saved email filters

Currently mboxrd only allows to specify an email to be checked for in sender or receiver header for message to be saved - or no filter at all. It would be nice to have multiple combinable filters.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.