Skip to content

Implement writ adopt --from-receipt #70

Open

Description

@David-Noble-at-work

Summary

Implement the --from-receipt flag for writ adopt that reads a lore receipt and adopts the packages-manifest.yaml and config files into the environment repository.

Current State

The function runAdoptFromReceipt() is a stub that returns an error (previously returned success, fixed in NobleFactor/noblefactor-engprod#317).

Location: internal/writ/commands.go:1202-1211

Requirements

  1. Read a lore receipt from the specified path (or ~/.local/state/devlore/receipts/lore-latest.yaml if not specified)
  2. Parse the receipt to extract:
    • packages-manifest.yaml that was deployed
    • Any config files that were templated
  3. Adopt these files into the specified layer/project using the existing adopt logic

Documentation References

Evidence of completion

  • writ adopt --from-receipt reads the most recent lore receipt
  • writ adopt --from-receipt <path> reads the specified receipt
  • Adopted files are placed in <layer>/<scope>/<project>/
  • Symlinks are created back to original locations
  • Tests verify the feature works correctly

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions