chore: on windows, create .bat instead of .exe

This commit is contained in:
zhom
2025-07-28 03:12:37 +04:00
parent 7067f8db75
commit c22eb4f39c
4 changed files with 27 additions and 17 deletions
+2 -1
View File
@@ -137,7 +137,8 @@ __DATA__
/// Create a Windows-compatible self-extracting executable
fn create_windows_executable(out: &Path, zip_data: Vec<u8>, build_id: &str) -> Result<()> {
let mut file = fs::File::create(out).context("Failed to create output executable")?;
let bat_path = out.with_extension("bat");
let mut file = fs::File::create(&bat_path).context("Failed to create output batch file")?;
let script = format!(
r#"@echo off