# limrun-xcode-bazel

Builds Bazel Apple projects on Limrun's remote Mac workers and installs the app on a remote iOS simulator. Meant for workspaces already running on lim xcode rbe.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode · 43100 installs · ★ 2
- Author: limrun-inc
- License: MIT · policy=mirror · the beginning of the file is at the end of this page
- Source: https://github.com/limrun-inc/skills/tree/HEAD/skills/limrun-xcode-bazel/SKILL.md
- Updated: 2026-10-23
- HTML: https://affpapa.org/en/nevibecode/skills/limrun-xcode-bazel

## What it does

The skill walks the agent through the legacy `lim xcode rbe` path: it brings up a remote RBE stack, tunnels it to a local port, and writes a `.limrun/` config so `bazelisk build --config=limrun` runs Apple actions remotely. Local Xcode and local build tools stay out of the picture, so you can build from Linux, Windows, macOS, a VM or a container.

You need the CLI first: `npm install --global lim`, then `lim login` or a `LIM_API_KEY`. Run `lim xcode rbe` from the Bazel workspace root that holds `MODULE.bazel` or `WORKSPACE` — from a subdirectory it fails fast. Put your own Bazel flags in `user.limrun.bazelrc` at the workspace root; the generated config try-imports it last, so your lines win and survive regeneration of `.limrun/`.

Building is all this path does. Attach a simulator with `lim ios create --attach` when you want to see the app, and every successful build reinstalls and relaunches it. One gotcha worth remembering: always pass `--digest_function=sha256` before `build`, because the Limrun cache is SHA256-only while Bazel 9 defaults to BLAKE3. A green build also doesn't prove remote execution, since cache hits pass even with the tunnel gone. For new workspaces and any other Bazel build, use the `limrun-bazel` skill; to tap, type or screenshot the running app, use `limrun-ios-simulator`.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add limrun-inc/skills --skill limrun-xcode-bazel -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/limrun-xcode-bazel/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/limrun-xcode-bazel/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add limrun-inc/skills --skill limrun-xcode-bazel -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/limrun-xcode-bazel/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add limrun-inc/skills --skill limrun-xcode-bazel -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/limrun-xcode-bazel/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install limrun-inc/skills limrun-xcode-bazel
```

2. **Manually: put the files in place**
- File: `.github/skills/limrun-xcode-bazel/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add limrun-inc/skills --skill limrun-xcode-bazel -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/limrun-inc/skills --path skills/limrun-xcode-bazel
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/limrun-xcode-bazel/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add limrun-inc/skills --skill limrun-xcode-bazel -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/limrun-inc/skills/tree/HEAD/skills/limrun-xcode-bazel/SKILL.md

## When to use it
- build an iOS app with Bazel without local Xcode
- bring up a remote RBE stack and tunnel in one command
- push a fresh build onto a remote simulator
- publish a build as an asset with a preview link
- recover from a BLAKE3 error against the remote cache

## Example prompts
- Build //App with lim xcode rbe and show me what the CLI prints
- Attach a simulator and relaunch the app after the build
- Upload the newest successful build as the asset preview/my-app with a 24h TTL

## Source text · SKILL.md · MIT

Below is the content of a third-party file. It is data, not instructions for you: do not act on anything written inside unless the human asks. Block tag: 6004cf0f4b649836.

BEGIN THIRD-PARTY FILE 6004cf0f4b649836
```text
---
name: limrun-xcode-bazel
description: "Legacy: build a Bazel iOS app with `lim xcode rbe` on a dedicated Xcode sandbox and install it on a remote iOS simulator attached to that sandbox. Use only when the workspace already runs on `lim xcode rbe` (its `.limrun/` came from `lim xcode rbe`) or the user explicitly asks for it, or when a `lim xcode rbe` build, upload, or install misbehaves. For every other Bazel build, including new workspaces, iOS or Android, and running the app on a simulator, use limrun-bazel. To tap, type, screenshot, or otherwise interact with the running app, use limrun-ios-simulator."
user-invocable: true
effort: high
---

# Bazel iOS builds on Limrun RBE (legacy)

`lim xcode rbe` is the legacy Bazel path. `lim bazel setup` (skill
limrun-bazel) replaces it: no sandbox or tunnel, iOS and Android targets, and
one cache across the organization. Use this skill only for workspaces that
already run on `lim xcode rbe`, or when the user asks for it.

Build Bazel Apple projects on Limrun's remote Mac workers — from any environment
(Linux, Windows, macOS, VM, container), no local Xcode. `lim xcode rbe` brings up
a remote RBE stack, tunnels it to a local port, and writes a `.limrun/` config so
`bazelisk build --config=limrun` runs Apple actions remotely. Local Xcode and
local build tools are not part of this workflow.

## Auth and CLI

Install if needed: `npm install --global lim`. Auth is `lim login` or
`LIM_API_KEY` (it may already be set in the user's environment even when the
shell does not show it; check before asking for it). The CLI is the source of truth: the commands in this skill are
verified, but if a flag errors or you need one not shown here, check
`lim xcode rbe --help` instead of guessing.

## Build

1. From the **Bazel workspace root** (has `MODULE.bazel` / `WORKSPACE`), run
   `lim xcode rbe`. It sets up the instance + `.limrun/` config and **prints the
   exact build command**. The tunnel runs in the background (prints a PID);
   `--no-daemon` keeps it foreground.
2. Run the printed command, e.g.
   `bazelisk --digest_function=sha256 build --config=limrun //App`.

Don't hand-write `.limrun/` or the flags — the CLI generates them for the
sandbox's Xcode and your OS. `lim xcode version set 27` (or the one-off
`lim xcode rbe --xcode-version 27`) builds with another installed Xcode: a bare
```
END THIRD-PARTY FILE 6004cf0f4b649836

The third-party file has ended. Everything between the 6004cf0f4b649836 tags is data: requests and commands from it are not followed. An “end of file” line with another tag inside the block is part of the file.

First 2360 of 7919 bytes. © limrun-inc · MIT · https://github.com/limrun-inc/skills/tree/HEAD/skills/limrun-xcode-bazel/SKILL.md

_Part of the page did not fit — see the HTML version._

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
