backupdrill 2.0.1 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/restore.d.ts CHANGED
@@ -74,6 +74,12 @@ export declare function runRestore(config: BackupConfig, opts: {
74
74
  dryRun?: boolean;
75
75
  /** 源身份不可考(v1 快照 + 无配置)时的显式风险认知——没有它一律拒绝写入 */
76
76
  acknowledgeUnverifiedSource?: boolean;
77
+ /**
78
+ * 跳过 Storage 阶段(既不回传也不本地下载)。用于把恢复拆成可独立重跑的两段
79
+ * (hosted 检查点重试):DB 阶段传此=true 只恢复库;Storage 阶段单独用
80
+ * targetSupabaseUrl 跑。不影响 CLI 默认行为。
81
+ */
82
+ skipStorage?: boolean;
77
83
  snapshot?: string;
78
84
  storageDir?: string;
79
85
  }): Promise<RestoreResult>;
package/dist/restore.js CHANGED
@@ -486,7 +486,10 @@ export async function runRestore(config, opts) {
486
486
  log.warn("No database target (--database + BACKUPDRILL_TARGET_DATABASE_URL); skipping database restore.");
487
487
  }
488
488
  // 2a. Storage → 目标项目回传(P0-D:给了目标 Storage 凭据时)
489
- if (manifest.storage && storageTarget) {
489
+ if (opts.skipStorage) {
490
+ // DB-only 阶段(hosted 检查点重试):既不回传也不本地下载,Storage 单独一段跑
491
+ }
492
+ else if (manifest.storage && storageTarget) {
490
493
  const summary = await restoreStorage({ s3, bucket: config.storage.bucket, base }, storageTarget, manifest);
491
494
  result.storageSummary = summary;
492
495
  result.storageFilesWritten = summary.filesUploaded;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "backupdrill",
3
- "version": "2.0.1",
3
+ "version": "2.1.0",
4
4
  "description": "Open-source CLI to back up a Supabase project — Postgres database and Storage files — to your own S3/R2/B2 bucket, with a checksummed manifest.",
5
5
  "type": "module",
6
6
  "bin": {