- Python 100%
| .gitignore | ||
| README.md | ||
| repack.py | ||
MightyText Linux Repack
A small Python tool that repackages the macOS MightyText DMG into a runnable Linux build (or AppImage).
What it does
- Extracts the
app.asarfrom the official macOS DMG. - Extracts the app source and applies small Electron compatibility patches for Linux.
- Downloads a Linux Electron runtime and rebuilds any native modules against it.
- Assembles a
MightyText-linux/folder with a launcher script and desktop entry. - Optionally builds a self-contained
MightyText.AppImage.
Requirements
- Python 3
udisksctl(usually provided byudisks2)- Node.js / npm (for
asar,node-gyp, and dependency installs) - Standard build tools (for compiling native modules)
Usage
Build a local runnable folder
python3 repack.py /path/to/MightyText-*.dmg
This creates a MightyText-linux/ folder next to the DMG.
Build an AppImage as well
python3 repack.py /path/to/MightyText-*.dmg --appimage
This produces both the MightyText-linux/ folder and a MightyText.AppImage.
Build only an AppImage
python3 repack.py /path/to/MightyText-*.dmg --appimage-only
This creates only the MightyText.AppImage and removes the staging folder afterwards.
Custom output directory or Electron version
python3 repack.py /path/to/MightyText-*.dmg \
--output-dir ./my-build \
--electron-version 41.3.0
Running the app
After building, you can launch it with:
./MightyText-linux/mightytext
A desktop entry is also installed to ~/.local/share/applications/ so MightyText appears in your app menu.
Patching
The script automatically patches a few macOS-specific Electron APIs so the app runs on Linux (e.g. replacing new-window handlers with setWindowOpenHandler, removing macOS-only title-bar styles, and fixing click-drag dead zones).
Caching
Downloaded files (Electron, extracted DMG contents) are cached in ~/.cache/mightytext-repack/ to speed up subsequent runs.