Skip to content

Structure

ArchiveAction

Archives the app for distribution.

struct ArchiveAction

Overview

  • iOS: Uses xcodebuild archive, producing a .xcarchive. The resulting archive is consumed by ExportAction to produce an IPA.

  • Android: Uses ./gradlew bundle<Variant>, producing a signed .aab (Android App Bundle). For APK-only builds use BuildAction instead. Gradle output is streamed live to the parent process (so a 15-minute build shows progress in CI), and a concise build summary (BUILD SUCCESSFUL …, the actionable tasks: … from cache … line, and any build-scan URL) is always printed at info level — even without --verbose. When outputPath is set, the produced .aab is copied to that deterministic path.

Usage

// iOS
let result = try await ArchiveAction().run(
    with: .init(scheme: "MyApp", exportMethod: "app-store"),
    context: context
)
print("Archive: \(result.archivePath)")

// Android
let result = try await ArchiveAction().run(
    with: .init(buildVariant: "release"),
    context: androidContext
)
print("AAB: \(result.aabPath ?? "N/A")")

Topics

Structures

Initializers

  • init()

    Creates an ArchiveAction.

Type Properties

Default Implementations

Relationships

Conforms To

  • Action
  • Swift.Sendable
  • Swift.SendableMetatype