Skip to main content

Drift Detection

Drift detection compares the actual state of your local workspace against the desired state defined by the workspace revision.

Types of drift

Drift typeDescription
Local modificationA generated file was edited locally
Missing fileA generated file was deleted
Remote updateWorkspace revision on the server is newer than local
Package updateA newer version exists for a selected package
Provider mismatchWorkspace expects a provider that is not rendered locally
Unknown fileA file in a Workloom-managed path is not owned by any package
Policy driftLocal config violates a workspace or org policy
Nested target driftA monorepo sub-target is missing expected files

Checking drift

wl status

Shows a human-readable summary:

Workspace: Platform API
Workspace revision: local 41, remote 42

Drift:
remote update available
modified: .claude/skills/security-review/SKILL.md
missing: .codex/config.toml

Suggested:
wl pull
wl restore .codex/config.toml

wl diff

Shows the exact content differences between local files and the expected rendered output.

wl sync --check

CI-safe drift check. No writes. Exits 0 if clean, non-zero if any drift is detected. Emits machine-readable diagnostics.

# In CI
wl sync --check || exit 1

Resolving drift

ActionEffect
wl pullFetch latest workspace revision and re-render
wl restoreRestore only Workloom-owned files to expected state
wl restore <path>Restore a specific file
wl pushPublish local changes as a new package version

Local overrides

When a developer modifies a generated file, Workloom does not fight it. Instead, wl status reports the modification and offers options:

  • Restore the server version
  • Push the change as a new package version
  • Keep the local override (it will be reported as drift until resolved)

Ownership tracking

Workloom tracks which package owns each generated file in .loom/state.json. The restore command uses this metadata to restore only files Workloom owns — it never deletes or overwrites unknown user files.