fix(bundler): debian package Installed-Size value (#1735)

This commit is contained in:
Lucas Fernandes Nogueira
2021-05-07 00:46:50 -03:00
committed by GitHub
parent e37e187d4a
commit 8e0d4f666c
2 changed files with 11 additions and 1 deletions

View File

@@ -0,0 +1,5 @@
---
"tauri-bundler": patch
---
Fixes the `Installed-Size` value on the debian package.

View File

@@ -255,7 +255,12 @@ fn generate_control_file(
)?;
writeln!(&mut file, "Version: {}", settings.version_string())?;
writeln!(&mut file, "Architecture: {}", arch)?;
writeln!(&mut file, "Installed-Size: {}", total_dir_size(data_dir)?)?;
// Installed-Size must be divided by 1024, see https://www.debian.org/doc/debian-policy/ch-controlfields.html#installed-size
writeln!(
&mut file,
"Installed-Size: {}",
total_dir_size(data_dir)? / 1024
)?;
let authors = settings
.authors_comma_separated()
.unwrap_or_else(String::new);