Skip to content

ContentStore: exportPack(adversaryIDs:) async -> URL helper method #142

@gwillish

Description

@gwillish

Per redesign-plan.md M8. Depends on #140. Unblocks #21 (DHPackExportSheet).

Critical file: Encounter/Services/ContentStore.swift

func exportPack(adversaryIDs: [Adversary.ID]) async throws -> URL
  • Assembles DHPackContent from the selected adversary IDs (local collection only)
  • Writes to FileManager.default.temporaryDirectory/<generated-name>.dhpack
  • Returns the URL for consumption by ShareLink / UIActivityViewController in DHPackExportSheet

Test first: ContentStoreTests — export with selected IDs produces a valid .dhpack file at the returned URL; content matches selected adversaries.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions