From 32ad6cab8d58d99ebd8a28e8fa6e6f4e587cb1e5 Mon Sep 17 00:00:00 2001 From: Christian Cleberg Date: Tue, 17 Mar 2026 23:19:43 -0500 Subject: v1.0 --- Hutch/Models/ArtifactInfo.swift | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 Hutch/Models/ArtifactInfo.swift (limited to 'Hutch/Models/ArtifactInfo.swift') diff --git a/Hutch/Models/ArtifactInfo.swift b/Hutch/Models/ArtifactInfo.swift new file mode 100644 index 0000000..dbe9d96 --- /dev/null +++ b/Hutch/Models/ArtifactInfo.swift @@ -0,0 +1,22 @@ +import Foundation + +/// An artifact with its parent reference name, used in the artifacts tab. +struct ArtifactInfo: Codable, Sendable, Identifiable { + let id: Int + let filename: String + let checksum: String + let size: Int + let url: URL +} + +struct ArtifactPage: Codable, Sendable { + let results: [ArtifactInfo] + let cursor: String? +} + +/// A reference (tag) that has associated artifacts. +struct ReferenceWithArtifacts: Codable, Sendable, Identifiable { + var id: String { name } + let name: String + let artifacts: [ArtifactInfo] +} -- cgit v1.2.3