Skip to content

Commit c2361ab

Browse files
committed
fix: resolve publish provenance rebase conflict
1 parent d13d71e commit c2361ab

1 file changed

Lines changed: 0 additions & 58 deletions

File tree

crates/vite_install/src/commands/publish.rs

Lines changed: 0 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,6 @@ pub struct PublishCommandOptions<'a> {
4040
pub publish_branch: Option<&'a str>,
4141
/// Requests a publish summary file/output when supported.
4242
pub report_summary: bool,
43-
/// Enables provenance publishing when supported.
44-
pub provenance: bool,
4543
/// Forces publish when the package manager exposes such a flag.
4644
pub force: bool,
4745
/// Requests machine-readable JSON output when supported.
@@ -136,10 +134,6 @@ impl PackageManager {
136134
args.push("--report-summary".into());
137135
}
138136

139-
if options.provenance {
140-
args.push("--provenance".into());
141-
}
142-
143137
if options.force {
144138
args.push("--force".into());
145139
}
@@ -194,10 +188,6 @@ impl PackageManager {
194188
args.push(otp.to_string());
195189
}
196190

197-
if options.provenance {
198-
args.push("--provenance".into());
199-
}
200-
201191
if options.force {
202192
args.push("--force".into());
203193
}
@@ -365,10 +355,6 @@ impl PackageManager {
365355
output::warn("--report-summary not supported by bun, ignoring flag");
366356
}
367357

368-
if options.provenance {
369-
output::warn("--provenance not supported by bun publish, ignoring flag");
370-
}
371-
372358
if options.force {
373359
output::warn("--force not supported by bun publish, ignoring flag");
374360
}
@@ -610,50 +596,6 @@ mod tests {
610596
assert_eq!(result.args, vec!["publish"]);
611597
}
612598

613-
#[test]
614-
fn test_pnpm_publish_provenance() {
615-
let pm = create_mock_package_manager(PackageManagerType::Pnpm, "10.0.0");
616-
let result = pm.resolve_publish_command(&PublishCommandOptions {
617-
provenance: true,
618-
..Default::default()
619-
});
620-
assert_eq!(result.bin_path, "pnpm");
621-
assert_eq!(result.args, vec!["publish", "--provenance"]);
622-
}
623-
624-
#[test]
625-
fn test_npm_publish_provenance() {
626-
let pm = create_mock_package_manager(PackageManagerType::Npm, "11.0.0");
627-
let result = pm.resolve_publish_command(&PublishCommandOptions {
628-
provenance: true,
629-
..Default::default()
630-
});
631-
assert_eq!(result.bin_path, "npm");
632-
assert_eq!(result.args, vec!["publish", "--provenance"]);
633-
}
634-
635-
#[test]
636-
fn test_yarn_publish_provenance() {
637-
let pm = create_mock_package_manager(PackageManagerType::Yarn, "4.0.0");
638-
let result = pm.resolve_publish_command(&PublishCommandOptions {
639-
provenance: true,
640-
..Default::default()
641-
});
642-
assert_eq!(result.bin_path, "npm");
643-
assert_eq!(result.args, vec!["publish", "--provenance"]);
644-
}
645-
646-
#[test]
647-
fn test_bun_publish_provenance_ignored() {
648-
let pm = create_mock_package_manager(PackageManagerType::Bun, "1.2.0");
649-
let result = pm.resolve_publish_command(&PublishCommandOptions {
650-
provenance: true,
651-
..Default::default()
652-
});
653-
assert_eq!(result.bin_path, "bun");
654-
assert_eq!(result.args, vec!["publish"]);
655-
}
656-
657599
#[test]
658600
fn test_pnpm_publish_otp() {
659601
let pm = create_mock_package_manager(PackageManagerType::Pnpm, "10.0.0");

0 commit comments

Comments
 (0)