Przejdź do treści
Biblioteka skilli
DevOps i chmura · Automatyzacja

macvm

/macvm

Tworzy i obsługuje maszyny wirtualne macOS, Linux i Windows ARM64 na Macu, uruchamia w nich polecenia i steruje pulpitem gościa.

Repozytorium
macvm ↗
Licencja
MIT
Ostatnia zmiana repozytorium
13.11.2026

Ocena i bezpieczeństwo

100/ 100Klasa: dobry
Format25 / 25
Frontmatter z nazwą i opisem, poprawna nazwa, opis do 1024 znaków, nazwa zgodna z folderem.
Odkrywalność25 / 25
Opis mówi, kiedy użyć skilla, ma sensowną długość i jest w 3. osobie.
Treść35 / 35
Co najmniej 150 słów i do 500 linii, nagłówki, listy kroków, przykłady albo kod.
Higiena15 / 15
Bez zaślepek typu TODO, bez ścieżek Windows, z licencją.
Ryzykobrak sygnałów w skanie
Pliki w paczce
4
Skrypty
0
Komentarze HTML
0
Adresy URL w SKILL.md
0
Przestarzałość

Brak sygnałów. Repozytorium zmienione 13.11.2026, bez odwołań do wycofanych modeli i API.

Licencja

MIT, otwarta: można używać i zmieniać, z zachowaniem informacji o autorze.

Co robi i kiedy

Tworzy i obsługuje maszyny wirtualne macOS, Linux i Windows ARM64 na Macu, uruchamia w nich polecenia i steruje pulpitem gościa.

Wyzwalacze z opisu

virtual machinespin up an Ubuntu to try thisclick something in Windows
Oryginalny opis (EN)

Create and operate macOS / Linux / Windows (ARM64) virtual machines on a Mac with the macvm command line — create, start, stop, suspend, run commands in the guest, SSH, port forwarding, snapshots and templates, and drive the guest desktop (UI automation, screenshots). Use this skill whenever a task involves running something in a VM or an isolated guest, testing on another OS, needing a clean Linux / Windows / macOS environment, or mentions macvm or MacVM — even if the user never says "virtual machine" and only says things like "spin up an Ubuntu to try this", "click something in Windows", or

Jak działa

  1. Finding the command
  2. Always pass --json
  3. Basic flow
  4. Confirm before acting
  5. Read details as needed
Sekcje z nagłówków SKILL.md, w oryginale · 64 linii, 839 słów
Podgląd SKILL.md
---
name: macvm
description: Create and operate macOS / Linux / Windows (ARM64) virtual machines on a Mac with the macvm command line — create, start, stop, suspend, run commands in the guest, SSH, port forwarding, snapshots and templates, and drive the guest desktop (UI automation, screenshots). Use this skill whenever a task involves running something in a VM or an isolated guest, testing on another OS, needing a clean Linux / Windows / macOS environment, or mentions macvm or MacVM — even if the user never says "virtual machine" and only says things like "spin up an Ubuntu to try this", "click something in Windows", or "run it in a sandbox".
---

# macvm

`macvm` is the command line that ships with MacVM. It is built on Apple Virtualization.framework (with an optional QEMU engine) and runs only on Apple silicon Macs.

## Finding the command

Try in order: `macvm` (the App puts a link in `~/.local/bin`), `/usr/local/bin/macvm`, `/Applications/MacVM.app/Contents/Resources/bin/macvm`. If none exists, MacVM is not installed: tell the user to install it, and do not substitute some other virtualization tool on your own.

`macvm <command> --help` is the authority on options; this skill only covers how to use them reliably.

## Always pass `--json`

With `--json`, standard output is exactly one line:

- Success: `{"schemaVersion":1,"result":…}`
- Failure: `{"schemaVersion":1,"error":{"code":"…","message":"…"}}`; some errors carry extra fields in `error` (see `stop` below)

Branch on `error.code` or the exit code; do not parse the human-readable output (its format is not stable). Exceptions: `exec`, `ssh` and `proxy` do not support `--json`, because their input and output belong to the guest command; the exit code of `exec` is the guest command's exit code.

| code | Exit code | Meaning and usual handling |
| --- | --- | --- |
| — (no code) | 1 | Other error; read the message |
| `vm_not_found` | 10 | Wrong name; run `macvm ls --json` first |
| `already_exists` | 11 | A VM or template with that name exists; pick another name or confirm the existing one is meant |
| `already_running` | 12 | Already running; changing configuration requires shutting down first |
| `not_running` | 13 | Run `start` first |
| `invalid_config` | 14 | Invalid argument or configuration; also returned when changing configuration while suspended |
| `unsupported` | 15 | Not supported on this host, engine or guest; also used when the agent is missing or too old — follow the message (usually `macvm agent install <name>`) |
| `entitlement_missing` | 16 | An unsigned macvm was used; use the copy bundled with the App. Also: a VM set to bridged networking in the app was run with `macvm run` (use `macvm start`) or with a macvm outside the App bundle |
| `timeout` | 17 | Timed out waiting; retry with a larger `--timeout` |
| `io` | 18 | File or socket read/write failed |
| `engine` | 19 | The virtualization engine reported an error; in UI automation it also means an element ID is stale |
| `snapshot_not_found` | 20 | Snapshot does not exist |
| `template_not_found` | 21 | Template does not exist |
| `permission_denied` | 22 | The guest has not granted the agent a permission (Accessibility or Screen Recording on macOS); the user must grant it inside the guest |

## Basic flow

```bash
macvm ls --json                       # result is an array of VMSummary: name, os, state (stopped|running|suspended), cpuCount, memorySize, ipAddress…
macvm start dev --json                # start in the background, return once ready
macvm wait dev --json                 # wait for the agent (or SSH); starts the VM if it is not running
macvm exec dev -- uname -a            # run in the guest; starts the VM if it is not running
macvm stop dev --json                 # graceful shutdown
```

- `stop` waits `--timeout` seconds (default 90) and then fails with `timeout`. In a macOS guest, apps that haven't quit can block the shutdown; the error then lists them in `error.blockingApps` (each with `name`, `pid` and usually `bundleId`). Tell the user which apps are blocking. Quitting an app in the guest can lose its unsaved work, so ask the user before doing it — they can quit it themselves, or with their consent run `macvm exec <vm> -- osascript -e 'quit app id "<bundleId>"'` — then run `stop` again. `stop --force` is the last resort and also needs confirmation.
- Run `ls` first and reuse an existing VM when one fits: creating a new one means downloading an image and installing an OS, which takes minutes to tens of minutes.
- Creating a VM (especially installing macOS, Windows or Ubuntu Desktop) takes a long time; run it in the background and tell the user what you are waiting for.
- The default VM directory holds the user's own VMs. When you create a VM just for testing, ask the user whether to delete it when you are done.

## Confirm before acting

These operations lose data or interrupt something the user is using; confirm with the user before running them: `rm`, `stop --force` (cuts power), `snapshot restore` (overwrites the current disk), `template rm`, `set` on a VM the user already had (changes its configuration), quitting apps in the guest (unsaved work is lost), and shutting down a VM you did not start yourself.

## Read details as needed

| Task | Read |
| --- | --- |
| Create a VM: choose the OS, image, engine, network, shared folders, templates | `references/create.md` |
| Run commands in the guest, SSH, ports, shared folder paths, snapshots and clones | `references/guest.md` |
| Drive the guest desktop: accessibility tree snapshots, clicking, typing, screenshots | `references/ui.md` |
Pliki w paczce (4)
  • SKILL.md 6 KB
  • references/create.md 3 KB
  • references/guest.md 6 KB
  • references/ui.md 3 KB

Wersje

W bazie nie ma innych skilli o nazwie macvm.

Migawka bazy z 13.11.2026 · wersja paczki f2041a15be21 (skrót SHA-256 całej paczki)

Pobrania w ostatnich 30 dniach: 0 · ranking

Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.

Podobne skille

  • 100linux-desktop-remote
    Steruje pulpitem Linux X11 przez SSH, znajdując przyciski po nazwie w AT-SPI, robiąc zrzuty i wpisując tekst.
  • 98gcloud-vm
    Tworzy, uruchamia i obsługuje maszyny wirtualne Google Cloud, zwłaszcza prawdziwy Windows i Linux, do zadań, których Mac i Docker nie wykonają.
  • 93ssh-server-ops
    Pomaga połączyć się przez SSH z serwerami Linux i HPC, diagnozować je i przesyłać pliki z systemów Windows, macOS lub Linux.
  • 98ssh-remote-desktop
    Wdraża pomocnika SSH do zdalnego pulpitu Windows 11, przesyła pliki, uruchamia programy i wykonuje zrzuty ekranu.
  • 98windows-vm
    Tworzy, zatrzymuje i łączy się przez SSH z bezgłowową maszyną wirtualną Windows 11 w Dockerze.
  • 100dd-agent-install-macos
    Instaluje Datadog Agent na Macu z instalatora macOS, z metrykami, logami i śledzeniem APM, np. na maszynie deweloperskiej lub CI.

Uwagi i zgłoszenia

Wiadomość trafi do Bartosza Sokolińskiego. Adres e-mail jest potrzebny tylko do odpowiedzi. Szczegóły w polityce prywatności.