import { Storage } from "@google-cloud/storage"; import { config } from "../config.js"; const storage = new Storage({ projectId: config.projectId }); export async function writeArtifactText(prefix: string, filename: string, content: string) { const bucket = storage.bucket(config.artifactsBucket); const file = bucket.file(`${prefix}/${filename}`); await file.save(content, { contentType: "text/plain" }); return { bucket: config.artifactsBucket, path: `${prefix}/${filename}` }; }