developing-on-linux

Installs Swift toolchain, swift-format, and SwiftLint on Linux to run format, lint, and typecheck gates locally.

1|Updated Apr 5, 2026
One-click install
npx skills add https://github.com/moolah-rocks/moolah-native --skill developing-on-linux-moolah-rocks
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: developing-on-linux
Source: https://github.com/moolah-rocks/moolah-native/tree/main/.claude/skills/developing-on-linux
Command: npx skills add https://github.com/moolah-rocks/moolah-native --skill developing-on-linux-moolah-rocks

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? The Moolah iOS/macOS project builds and tests only on macOS via xcodebuild, so developers working from a Linux box (Claude Code on the web, Linux containers, CI debugging) cannot run just format-check or compile checks, forcing a 25-minute CI round-trip to discover formatting or compile errors. ## Core Features & Use Cases - Version-matched toolchain setup: Installs the Swift 6.2 Linux toolchain plus SwiftLint at the exact versions pinned in scripts/install-ci-tools.sh, ensuring byte-for-byte parity with CI's swift-format output. - Local format and lint gates: Reproduces just format-check locally with swift-format byte-parity checks via cmp and swiftlint lint --strict, including guidance on rules like multiline_parameters, function_parameter_count, and identifier_name. - Type-checking without Xcode: Builds a throwaway swiftc -typecheck harness of Foundation-only files to catch compile errors in the layer being edited, shimming Darwin-only APIs like OSAllocatedUnfairLock. - Use Case: You are in a Linux container fixing a lint failure. Source the env file, run swift-format and swiftlint at the pinned versions, type-check your edited layer, and push only when all gates pass locally. ## Quick Start Set up the Swift toolchain and SwiftLint on this Linux machine, then run the format-check and lint gates on my changed Swift files before I push.

Frequently Asked Questions about developing-on-linux

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I run swift-format and SwiftLint on Linux?▼

Download the Swift 6.2 Linux toolchain tarball from swift.org, which bundles swift-format, then fetch the swiftlint_linux_amd64.zip binary from the realm/SwiftLint GitHub releases at the pinned version. Add both to your PATH and set LD_LIBRARY_PATH to the toolchain's usr/lib directory.

How do I check Swift formatting without Xcode or a Mac?▼

Run swift-format format with the repo's .swift-format configuration and compare output byte-for-byte using cmp against each file. This reproduces exactly what CI's format-check asserts, catching formatting drift before pushing.

Why does SwiftLint fail with libsourcekitdInProc.so loading error on Linux?▼

SwiftLint needs the libsourcekitdInProc.so library shipped inside the full Swift toolchain, not the standalone binary. Set LD_LIBRARY_PATH to the toolchain's usr/lib directory so the loader can find it.

Can I compile an iOS or macOS Swift app on Linux?▼

No, the full app cannot build on Linux because it uses Darwin-only APIs like OSLog, CryptoKit, and the iOS/macOS SDKs. You can still type-check individual layers with swiftc -typecheck by assembling only the Foundation-only files they depend on.

Why does swift-format produce different output than CI?▼

CI pins an exact swift-format version such as 602.0.0, and different versions reformat differently, failing the byte-parity check. Check the PINNED_TOOLS block in scripts/install-ci-tools.sh and install the matching Swift toolchain release.