Skip to content

Repository files navigation

LarkSync

Sync Lark Drive → Google Drive, automatically.
A lightweight desktop app for seamless file synchronization — available for macOS and Windows.

Platform - macOS Platform - Windows Python License Release Build Windows Author


Screenshot

Screenshot placeholder — add a screenshot of the menu bar and settings window here.

LarkSync menu bar screenshot


Features

  • Cross-platform — Available for both macOS and Windows
  • Automatic sync — Schedule syncs daily, weekly, or run on demand
  • System tray integration — Lives quietly in the macOS menu bar or Windows system tray
  • Lark Drive support — Works with Lark (Feishu) custom app credentials
  • Google Drive upload — Uploads to any target folder in your Google Drive via OAuth 2.0
  • Format conversion — Lark-native files (Docs, Sheets, Mindnotes) exported to Google-compatible formats (Docx, Xlsx, PDF)
  • Incremental sync — Only sync new and modified files since last run (faster)
  • Smart Settings UX — Sync Now saves + triggers sync; Cancel Sync mid-flight; singleton window guard
  • Secure credential fields — All API keys and IDs hidden by default with a 👁 eye toggle
  • Setup Wizard — Guided first-time configuration for both Lark and Google credentials
  • Sync log — In-app log viewer for reviewing sync history and diagnosing errors
  • Lark group notification — Get notified in your Lark group chat after each sync
  • Launch at login — Auto-start via macOS Login Items or Windows Registry
  • Lightweight — Built with Python + PyQt6, packaged as .app (macOS) or .exe (Windows)

Requirements

External Credentials (Required for all users)

  • Lark App with Drive read permissions (App ID + App Secret) — Create one here
  • Google Cloud project with Drive API enabled (credentials.json) — Set up here

Pre-built App (Recommended)

Platform Requirements
macOS macOS 12 Monterey or later (Apple Silicon and Intel)
Windows Windows 10 or later (64-bit)

No Python installation required for pre-built apps.

Build from Source

  • Python 3.11 or later
  • pip / virtualenv

🍎 macOS — Quick Install

  1. Download the latest LarkSync.dmg from Releases.
  2. Open the DMG and drag LarkSync.app to your Applications folder.
  3. First launch: Right-click the app → OpenOpen (bypasses Gatekeeper for unsigned apps).
  4. The Setup Wizard will guide you through the rest.

If macOS says the app is damaged, run: xattr -cr /Applications/LarkSync.app


🪟 Windows — Quick Install

  1. Go to GitHub Actions → Build LarkSync (Windows). or download here Download .exe
  2. Click the latest successful build run (green ✅).
  3. Scroll to the Artifacts section → Download LarkSync-Windows.zip.
  4. Extract the ZIP → Run LarkSync.exe.
  5. The Setup Wizard will guide you through the rest.

Note: The app will appear in your system tray (near the clock on your taskbar). Right-click the tray icon to access all features.


Quick Start

After installation, the Setup Wizard will ask for:

Step What You Need
Lark App credentials App ID + App Secret from open.larksuite.com/app
Google credentials credentials.json from console.cloud.google.com
Google Drive Folder ID From the Google Drive folder URL (optional)
Sync schedule Manual, Daily, or Weekly
Lark notification Group Chat ID (optional)

See the full User Guide for step-by-step instructions.


Build from Source

macOS

# 1. Clone the repository
git clone https://github.com/khiemnguyendinh/larksync.git
cd larksync

# 2. Create and activate a virtual environment
python3 -m venv venv
source venv/bin/activate

# 3. Install dependencies
pip install -r requirements.txt

# 4. Run in development mode
python main.py

# 5. Build the .app bundle + .dmg installer
bash build.sh
# Output: dist/LarkSync.app + dist/LarkSync.dmg

Windows

# 1. Clone the repository
git clone https://github.com/khiemnguyendinh/larksync.git
cd larksync

# 2. Create and activate a virtual environment
python -m venv venv
venv\Scripts\activate

# 3. Install dependencies
pip install -r requirements_windows.txt

# 4. Run in development mode
python main.py

# 5. Build the .exe (using PyInstaller)
build_windows.cmd
# Output: dist\LarkSync\LarkSync.exe

Tip: You don't need a Windows machine to build the Windows version! The GitHub Actions workflow automatically builds the .exe whenever code is pushed to the windows branch. See .github/workflows/build-windows.yml.

Dependencies:

  • PyQt6 — Cross-platform UI framework
  • google-api-python-client — Google Drive API
  • google-auth-oauthlib — Google OAuth flow
  • requests — HTTP client for Lark API
  • py2app — macOS app bundler (macOS build only)
  • pyinstaller — Windows executable bundler (Windows build only)

Project Structure

larksync/
├── main.py                  # App entry point (cross-platform)
├── app/                     # UI + application layer
│   ├── config_manager.py    # Config persistence + launch-at-login
│   ├── tray_app.py          # System tray / menu bar logic + scheduler
│   ├── settings_dialog.py   # Tabbed settings window
│   ├── setup_wizard.py      # First-run 4-step wizard
│   ├── sync_thread.py       # Background sync QThread
│   ├── log_viewer.py        # Sync log viewer
│   ├── mac_menu_bar.py      # macOS native application menu bar
│   └── win_menu.py          # Windows About dialog
├── sync/                    # Sync engine (no UI dependencies)
│   ├── lark_auth.py         # Lark OAuth flows + token management
│   ├── lark_client.py       # Lark Drive API client
│   ├── google_client.py     # Google Drive API client
│   ├── sync_engine.py       # Core sync logic
│   └── lark_notifier.py     # Post-sync group chat notification
├── assets/                  # Icons and build assets
├── docs/                    # Documentation
│   ├── ARCHITECTURE.md      # System design + module reference (NEW)
│   ├── DEVELOPER_GUIDE.md   # Developer onboarding + how-to guides (NEW)
│   ├── USER_GUIDE.md        # End-user guide (EN + VI)
│   ├── TERMS_OF_USE.md
│   └── DISCLAIMER.md
├── .github/workflows/       # CI/CD
│   └── build-windows.yml    # Auto-build Windows .exe on push
├── setup.py                 # py2app configuration (macOS)
├── build.sh                 # macOS build script (.app + .dmg)
├── build_windows.py         # PyInstaller config (Windows)
├── build_windows.cmd        # Windows build script
├── requirements.txt         # macOS dependencies
└── requirements_windows.txt # Windows dependencies

Branches

Branch Purpose
main Stable release — merged from platform branches
macos Active macOS development
windows Active Windows development + CI build

Documentation

Document Audience Description
User Guide End users Installation, setup, and usage instructions (EN + VI)
Architecture Developers System design, module reference, data flows, build pipeline
Developer Guide Developers Dev environment, patterns, how-to guides, pitfalls
Terms of Use End users Terms governing use of LarkSync (EN + VI)
Disclaimer End users Liability disclaimer and warranty information (EN + VI)

Contributing

Contributions are welcome! Here's how to get started:

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/your-feature-name
  3. Make your changes and commit: git commit -m "Add: your feature description"
  4. Push to your fork: git push origin feature/your-feature-name
  5. Open a Pull Request

Please:

  • Follow the existing code style
  • Test on both platforms if possible (macOS + Windows)
  • Update documentation as needed
  • Do not commit credentials or token files

For bugs, please open a GitHub Issue with:

  • Your OS (macOS / Windows) and version
  • A description of the problem
  • The relevant section of your sync log

License

This project is licensed under the MIT License — see the LICENSE file for details.


Credits & Acknowledgments

Developer: Khiem Nguyen Dinh (@khiemnguyendinh)
Organization: Kstudy Academy
Contact: khiem@kstudy.edu.vn

Built with:


Note: LarkSync is an independent open-source project and is not affiliated with, endorsed by, or sponsored by ByteDance (Lark/Feishu) or Google LLC.

© 2026 Khiem Nguyen Dinh · Kstudy Academy

About

Sync Data from Larksuite/ Feishu to Google Drive

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages