mirror of
https://github.com/zhom/banderole.git
synced 2026-06-13 01:27:47 +02:00
chore: on windows, create .bat instead of .exe
This commit is contained in:
+1
-1
@@ -1089,7 +1089,7 @@ fn resolve_output_path(
|
||||
}
|
||||
|
||||
let ext = if Platform::current().is_windows() {
|
||||
".exe"
|
||||
".bat"
|
||||
} else {
|
||||
""
|
||||
};
|
||||
|
||||
+2
-1
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user