Skip to content

cub space unarchive

cub space unarchive

Unarchive a space or multiple spaces

Synopsis

Unarchive spaces archived with cub space delete --archive.

An archived space is named by a slug made from its ID, id followed by the UUID, or by its UUID. Its slug is restored unless another space has taken it since, in which case it keeps the one made from its ID, and can be renamed. A space archived with --recursive is unarchived only with --recursive, which unarchives what its archive archived: anything in it archived before or since stays archived. The change orders the archive aborted stay aborted.

Unarchiving is refused while what it would bring back names an entity that is still archived, such as a trigger running an invocation in another archived space. Unarchive that one first, or in the same request.

Examples:

  # Unarchive one space and what was archived with it
  cub space unarchive --recursive id5f0c1d2e-0a4b-4c3d-9e8f-7a6b5c4d3e2f

  # Unarchive the archived space whose slug was my-space
  cub space unarchive --recursive --where "Labels.ArchivedSlug = 'my-space'"
cub space unarchive [<slug or id>] [flags]

Options

      --filter string   Filter entity to apply to the list. Specify as 'space/filter' for cross-space filters or just 'filter' for current space. Supports both slugs and UUIDs. The filter will be combined with any --where clause using AND logic. Examples: "production-filters/security-check", "my-filter-uuid", "validation-rules"
  -h, --help            help for unarchive
  -o, --output string   Output format. One of: json, yaml, name, wide, mutations, jq=<expr>, yq=<expr>, custom-columns=<spec>
      --quiet           No default output.
      --recursive       Also unarchive what was archived with each space, which a space archived with --recursive requires
      --verbose         Detailed output, additive with default output
      --where string    where filter to select the archived spaces to unarchive

Options inherited from parent commands

      --context string   The context to use for this command
      --debug            Debug output

SEE ALSO