Skip to content
This repository was archived by the owner on Feb 18, 2025. It is now read-only.

Latest commit

 

History

History
80 lines (55 loc) · 1.94 KB

remote_dev.md

File metadata and controls

80 lines (55 loc) · 1.94 KB

Remote Development Environment

A lot of our engineers work on macOS on ARM-based machines. Due LibreOffice having problems with cross-compiling across architectures, we have a containerized remote development environment for LOK WASM ready to go.

Mutagen.io

Mutagen is an excellent tool that allows transparent, fast syncing of local project files with the remote development environment. This allows you to work on the project locally, without any latency to your keypresses. It also allows easy, secure forwarding of any ports from the remote development environment.

Installing Mutagen with brew

brew install mutagen-io/mutagen/mutagen

Using Mutagen

Start syncing and forwarding:

# This can take a while at the beginning, changes after that are pretty fast
mutagen project start

Stop syncing and forwarding:

mutagen project terminate

Check sync status:

mutagen sync monitor

Remote Scripts

You'll still need to trigger builds, among other things.

SSH into your development environment:

./remote/ssh

Make a build:

./remote/build

Start the QA environment remotely:

# this is accessible from your localhost, thanks to mutagen's connection forwarding
# it's slower to load because it's not a local server, so you can also wait for a build to finish and run the QA env locally
./remote/qa

Typical Development Cycle

Initial setup:

# sync project files
mutagen project start
# setup emscripten toolchain for clangd
./scripts/setup.sh
# build the compile commands for clangd and transform them for local use
./remote/clangd

After making modifications, make a build (it will automatically sync locally, but takes about as long as downloading 100MiB+ files in addition to the build time):

# make a build
./remote/build
# optional: wait for file sync activity to say Awaiting changes, that means everything is synced
mutagen sync monitor