package archive import ( "context" "fmt" "github.com/leonmika/wails-release/internal/runner" ) // ZipApp wraps a .app bundle into a .app.zip via ditto, preserving // extended attributes and producing an archive Apple's notary service // will accept. func ZipApp(ctx context.Context, r runner.Runner, app, zipPath string) error { _, err := r.Run(ctx, runner.Spec{ Name: "ditto", Args: []string{"-c", "-k", "--keepParent", app, zipPath}, }) if err != nil { return fmt.Errorf("ditto archive %s -> %s: %w", app, zipPath, err) } return nil }