A LTC timecode generator webapp that shows the currently running LTC time, and has a digital clapper funtion. Primarily vibecoded to be good enough for practical application.
Setup:
cargo install cargo-zigbuildCompilation:
cargo zigbuild --releasedocker build --platform linux/386 -t ltc-debian11-builder -f Dockerfile.gui-build .
docker run --rm \
-v "$(pwd)":/app \
-v "$(pwd)/.cargo_cache:/usr/local/cargo/registry" \
-w /app/ltc-gui \
ltc-debian11-builder \
cargo zigbuild --target i686-unknown-linux-gnu.2.31 --releasecd ltc-gui
cargo run # Debug
cargo run --release # Release (12MB stripped)
LIBGL_ALWAYS_SOFTWARE=1 cargo run # Force software rendering for GPU-less testingPackaging your React/Vite application into a native desktop app using Tauri is a highly efficient choice. Tauri utilizes the system’s native webview (WebKit on Linux/macOS, WebView2 on Windows) combined with a robust Rust backend. This keeps the final binary size extremely small (around 5–10 MB) and uses very little memory compared to Electron. Here is a step-by-step guide tailored to your specific React project to turn it into a standalone desktop application.
Before you begin, your local development machine needs the Rust compiler and system webview packages installed.
Linux (Debian/Ubuntu):
sudo apt update
sudo apt install -y libwebkit2gtk-4.1-dev build-essential curl wget file libssl-dev libgtk-3-dev
# For 32 bit deployment
sudo apt install libwebkit2gtk-4.1-dev:armhf # ARMv7
sudo apt install libwebkit2gtk-4.1-dev:i386 # i686macOS:
Install Xcode Command Line Tools:
xcode-select --installWindows:
Download and run the Rustup installer and install the C++ build tools via Visual Studio Build Tools.
Once prerequisites are met, install Rust:
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | shcargo install tauri-cli --version "^2.0.0" --lockedYou can now run your application in a local native desktop window. Tauri will start Vite in the background, spin up the Rust core, and display your React interface inside the native webview:
npx tauri devWhen you are ready to package your application into a production-ready, standalone binary, run:
npm run build
cd src-tauri
cargo tauri build
# npx tauri buildThis command will:
- Run npm run build to compile your TypeScript/React code into optimized HTML, JS, and CSS inside /dist.
- Compile the Rust backend from source.
- Package everything into a standalone executable (e.g., .deb / .AppImage on Linux, .app / .dmg on macOS, .msi on Windows) inside src-tauri/target/release/bundle/.
To build 32bit versions, make sure you have docker installed on you system, then:
./build-32bit.shnpm version patch # 0.1.0 → 0.1.1, syncs all files, creates git tag v0.1.1
npm version minor # 0.1.0 → 0.2.0, syncs all files, creates git tag v0.2.0
npm version major # 0.1.0 → 1.0.0, syncs all files, creates git tag v1.0.0
npm run version:sync # manual re-sync without bumpingAfter npm version, run npm install and cargo build in each crate to
update lock files.
sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
sudo chmod a+r /etc/apt/keyrings/docker.asc
echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu $(. /etc/os-release && echo "$VERSION_CODENAME") stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
sudo apt update
sudo apt install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin Allow non root (i.e. you) users to run docker:
sudo usermod -aG docker $USER
newgrp docker