Skip to content

oktet-tech/winmail2ical

Repository files navigation

winmail2ics

Extract iCal from winmail.dat (TNEF) files with Russian encoding support.

Features

  • Parse Microsoft Outlook TNEF/winmail.dat attachments
  • Handle CP1251, KOI8-R, and other Russian character encodings
  • Generate Mac-compatible iCal (.ics) files with proper timezone support
  • Auto-detect timezone from meeting data (e.g., "Asia/Novosibirsk")
  • Double-click integration via macOS app bundle

Installation

Requires uv:

# Install uv if not already installed
curl -LsSf https://astral.sh/uv/install.sh | sh

# Clone/download this project, then install globally:
cd winmaiil
uv tool install .

This installs winmail2ics command globally in ~/.local/bin/.

Usage

Command Line

# Basic usage - creates .ics file in same folder
winmail2ics winmail.dat

# Specify output file
winmail2ics winmail.dat -o meeting.ics

# Override timezone
winmail2ics winmail.dat --tz Europe/Moscow

# Quiet mode (no meeting details printed)
winmail2ics winmail.dat -q

Double-Click Integration (macOS)

Build and install the native app:

cd winmaiil
uv run pyinstaller winmail2ical.spec --clean --noconfirm
cp -r dist/Winmail2iCal.app /Applications/
xattr -cr /Applications/Winmail2iCal.app

Then set up file association:

  1. Right-click any .dat file → "Get Info" (⌘+I)
  2. Under "Open with:", select Winmail2iCal from Applications
  3. Click "Change All..." to make it default for all .dat files
  4. If Gatekeeper blocks, go to System Settings → Privacy & Security → "Open Anyway"

Dependencies

  • tnefparse - TNEF format decoder
  • icalendar - iCalendar file generator
  • pytz - Timezone handling

About

Mac app to handle tricky windmail.dat files

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages