hull workspace diff
Synopsis
hull workspace diff renders every member declared in hull-workspace.yaml and
compares each one against its own recorded state — what hull stored the last
time that member was applied. It prints, grouped by member, the per-resource
changes that a hull workspace upgrade would make. Nothing is applied.
When to use it
- Before an upgrade, to review every member’s pending changes in one report.
- As a CI change-detection gate: render the workspace, see what would move, and decide whether to proceed.
What happens
- Reads
hull-workspace.yamlfrom--dir(default.) and orders the members by dependency. - Renders each member locally and reads its stored state from the member’s namespace (best-effort — with no reachable cluster or no prior state, every resource shows as a create).
- Prints a
=== <member> (ns=<namespace>) ===header per member, then eitherno changesor the per-resource change preview. - Ends each changed member with a
Summary: N added, N changed, N removed.line. No resources are modified.
Usage
hull workspace diff [flags]
Flags
| Flag | Type | Default | Description |
|---|---|---|---|
--dir |
string | . |
Directory containing hull-workspace.yaml. Point it elsewhere to diff a workspace in another directory. |
Inherits the global flags.
Worked example
INPUT — hull-workspace.yaml with two members, where api depends on
postgres. postgres matches its recorded state; api’s package now sets
replicas: 3 where the stored state has 1:
apiVersion: hull/v1
defaults:
namespace: apps
members:
- name: postgres
path: ./postgres # unchanged since last apply
- name: api
path: ./api # replicas edited 1 → 3
dependsOn: [postgres]
Run it:
hull workspace diff
OUTPUT:
=== postgres (ns=apps) ===
no changes
=== api (ns=apps) ===
~ update Deployment/api (namespace apps)
~ spec.replicas
- 1 (state)
+ 3
Summary: 0 added, 1 changed, 0 removed.
postgres renders identically to its stored state, so its section reads
no changes. api renders with replicas: 3; the - 1 (state) line is the
value hull recorded, and + 3 is what the package now produces — the one
change a hull workspace upgrade would apply. Members are shown in dependency
order, postgres before api.
See also
workspace— the workspace indexworkspace plan— preview the order of membersworkspace upgrade— apply the changes shown herediff— the single-release analogue